diff --git a/tests/unit/bootstrap.php b/tests/unit/bootstrap.php index 23120b4988d80..f58b7f790109c 100644 --- a/tests/unit/bootstrap.php +++ b/tests/unit/bootstrap.php @@ -21,7 +21,6 @@ */ function jexit($message = 0) { - return; } define('_JEXEC', 1); diff --git a/tests/unit/stubs/discover1/challenger.php b/tests/unit/stubs/discover1/challenger.php index cd8065a10bf00..37acc3f82e162 100644 --- a/tests/unit/stubs/discover1/challenger.php +++ b/tests/unit/stubs/discover1/challenger.php @@ -1 +1 @@ - +load(JFormDataHelper::$loadDocument); - $originalset = $originalform->getXml()->xpath('/form/fields/field'); + $originalForm = new JFormInspector('form1'); + $originalForm->load(JFormDataHelper::$loadDocument); + $originalSet = $originalForm->getXml()->xpath('/form/fields/field'); $set = $form->getXml()->xpath('/form/fields/field'); - for ($i = 0; $i < count($originalset); $i++) + for ($i = 0, $iMax = count($originalSet); $i < $iMax; ++$i) { $this->assertThat( - (string) ($originalset[$i]->attributes()->name) == (string) ($set[$i]->attributes()->name), + (string) $originalSet[$i]->attributes()->name === (string) $set[$i]->attributes()->name, $this->isTrue(), 'Line:' . __LINE__ . ' Replace should leave fields in the original order.' ); diff --git a/tests/unit/suites/libraries/joomla/log/loggers/JLogLoggerCallbackTest.php b/tests/unit/suites/libraries/joomla/log/loggers/JLogLoggerCallbackTest.php index dd363d6a2ae93..f6d31f2921e86 100644 --- a/tests/unit/suites/libraries/joomla/log/loggers/JLogLoggerCallbackTest.php +++ b/tests/unit/suites/libraries/joomla/log/loggers/JLogLoggerCallbackTest.php @@ -56,7 +56,6 @@ public function testConstructor02() // Create a callback function (since php 5.3) $callback = function ($entry) { - return; }; // Setup the basic configuration. diff --git a/tests/unit/suites/libraries/joomla/session/JSessionTest.php b/tests/unit/suites/libraries/joomla/session/JSessionTest.php index f4e6cb5783d82..00874fba88d2b 100644 --- a/tests/unit/suites/libraries/joomla/session/JSessionTest.php +++ b/tests/unit/suites/libraries/joomla/session/JSessionTest.php @@ -81,7 +81,7 @@ protected function tearDown() * * @return array */ - Public function casesGetInstance() + public function casesGetInstance() { return array( 'first_instance' => array( diff --git a/tests/unit/suites/libraries/legacy/error/JErrorTest.php b/tests/unit/suites/libraries/legacy/error/JErrorTest.php index fff5cc842e734..e4d624414ee6b 100644 --- a/tests/unit/suites/libraries/legacy/error/JErrorTest.php +++ b/tests/unit/suites/libraries/legacy/error/JErrorTest.php @@ -165,6 +165,5 @@ public function testSetErrorHandling() */ public function callbackHandler() { - return; } } diff --git a/tests/unit/suites/libraries/legacy/model/stubs/name.php b/tests/unit/suites/libraries/legacy/model/stubs/name.php index 05f6679020c7a..d584f1519c29f 100644 --- a/tests/unit/suites/libraries/legacy/model/stubs/name.php +++ b/tests/unit/suites/libraries/legacy/model/stubs/name.php @@ -26,6 +26,5 @@ class NokeywordInName extends JModelLegacy */ public function __construct() { - return; } }