From f043a9d71d08f285d0035c8505306a8a5bbbaa39 Mon Sep 17 00:00:00 2001 From: Andres Rey Date: Tue, 28 Nov 2017 19:26:44 +0000 Subject: Minor fixes --- test/ReadabilityTest.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'test') diff --git a/test/ReadabilityTest.php b/test/ReadabilityTest.php index d019192..93214ae 100644 --- a/test/ReadabilityTest.php +++ b/test/ReadabilityTest.php @@ -48,9 +48,16 @@ class ReadabilityTest extends \PHPUnit_Framework_TestCase if ($config) { $options = array_merge($options, $config); } + $configuration = new Configuration(); + + foreach($options as $key => $value){ + $name = 'set' . $key; + $configuration->$name($value); + } - $readability = new HTMLParser($options); + $readability = new Readability($configuration); $result = $readability->parse($html); + $this->assertEquals($expectedImages, json_encode($result['images'])); } -- cgit v1.2.3