diff --git a/tests/Misd/Linkify/Test/LinkifyTest.php b/tests/Misd/Linkify/Test/LinkifyTest.php index a940cc4..927b4cf 100644 --- a/tests/Misd/Linkify/Test/LinkifyTest.php +++ b/tests/Misd/Linkify/Test/LinkifyTest.php @@ -46,10 +46,19 @@ public function emailProvider() public function ignoreProvider() { - return array( - array($this->loadData('ignore.json')), - array($this->loadData('ignore-options.json')), - ); + $out = array(); + foreach(array( + $this->loadData('ignore.json'), + $this->loadData('ignore-options.json'), + ) as $data) { + foreach($data['tests'] as $test) { + $out[] = array( + $data['options'], + $test, + ); + } + } + return $out; } public function callbackProvider() diff --git a/tests/Misd/Linkify/Test/ProcessEmailsTest.php b/tests/Misd/Linkify/Test/ProcessEmailsTest.php index 91b58b6..3c91082 100644 --- a/tests/Misd/Linkify/Test/ProcessEmailsTest.php +++ b/tests/Misd/Linkify/Test/ProcessEmailsTest.php @@ -73,12 +73,9 @@ public function avoidUrlLinks(array $data) * @test * @dataProvider ignoreProvider */ - public function avoidNonLinks(array $data) + public function avoidNonLinks(array $options, $test) { - $linkify = new Linkify($data['options']); - - foreach ($data['tests'] as $test) { - $this->assertEquals($test, $linkify->processEmails($test)); - } + $linkify = new Linkify($options); + $this->assertEquals($test, $linkify->processEmails($test)); } } diff --git a/tests/Misd/Linkify/Test/ProcessTest.php b/tests/Misd/Linkify/Test/ProcessTest.php index 7e57ff8..b8e88d8 100644 --- a/tests/Misd/Linkify/Test/ProcessTest.php +++ b/tests/Misd/Linkify/Test/ProcessTest.php @@ -70,12 +70,9 @@ public function makeEmailLinks(array $data) * @test * @dataProvider ignoreProvider */ - public function avoidNonLinks(array $data) + public function avoidNonLinks(array $options, $test) { - $linkify = new Linkify($data['options']); - - foreach ($data['tests'] as $test) { - $this->assertEquals($test, $linkify->process($test)); - } + $linkify = new Linkify($options); + $this->assertEquals($test, $linkify->process($test)); } } diff --git a/tests/Misd/Linkify/Test/ProcessUrlsTest.php b/tests/Misd/Linkify/Test/ProcessUrlsTest.php index cfef7a9..1e59479 100644 --- a/tests/Misd/Linkify/Test/ProcessUrlsTest.php +++ b/tests/Misd/Linkify/Test/ProcessUrlsTest.php @@ -69,12 +69,9 @@ public function avoidEmailLinks(array $data) * @test * @dataProvider ignoreProvider */ - public function avoidNonLinks(array $data) + public function avoidNonLinks(array $options, $test) { - $linkify = new Linkify($data['options']); - - foreach ($data['tests'] as $test) { - $this->assertEquals($test, $linkify->processUrls($test)); - } + $linkify = new Linkify($options); + $this->assertEquals($test, $linkify->processUrls($test)); } }