From d944bf7ac55c17f7cccedc33ea9d6e50565cd324 Mon Sep 17 00:00:00 2001 From: Jamie Snape Date: Tue, 24 Jun 2014 13:13:15 -0400 Subject: [PATCH] Fix failing tests --- modules/api/controllers/IndexController.php | 4 ++-- tests/PHPUnitMySQL.php | 5 +---- tests/PHPUnitPgSQL.php | 5 +---- 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/modules/api/controllers/IndexController.php b/modules/api/controllers/IndexController.php index cd7080e9a..708cabe47 100644 --- a/modules/api/controllers/IndexController.php +++ b/modules/api/controllers/IndexController.php @@ -185,8 +185,8 @@ function jsonAction() } /** Allows components to call redirect */ - function redirect($url) + function redirect($url, array $options = array()) { - $this->_redirect($url); + $this->_redirect($url, $options); } } // end class diff --git a/tests/PHPUnitMySQL.php b/tests/PHPUnitMySQL.php index fe7bbef83..77273d74c 100644 --- a/tests/PHPUnitMySQL.php +++ b/tests/PHPUnitMySQL.php @@ -63,8 +63,7 @@ copy($base_path . '/tests/configs/mysql.ini', $base_path . '/tests/configs/lock.mysql.ini'); -require_once 'PHP/CodeCoverage/Filter.php'; -PHP_CodeCoverage_Filter::getInstance()->addFileToBlacklist(__FILE__, 'PHPUNIT'); +define('PHPUnit_MAIN_METHOD', 'PHPUnit_TextUI_Command::main'); if (strpos('@php_bin@', '@php_bin') === 0) { set_include_path(dirname(__FILE__) . PATH_SEPARATOR . get_include_path()); @@ -72,6 +71,4 @@ require_once 'PHPUnit/Autoload.php'; -define('PHPUnit_MAIN_METHOD', 'PHPUnit_TextUI_Command::main'); - PHPUnit_TextUI_Command::main(); diff --git a/tests/PHPUnitPgSQL.php b/tests/PHPUnitPgSQL.php index 8c04face6..72924d609 100644 --- a/tests/PHPUnitPgSQL.php +++ b/tests/PHPUnitPgSQL.php @@ -63,8 +63,7 @@ copy($base_path . '/tests/configs/pgsql.ini', $base_path . '/tests/configs/lock.pgsql.ini'); -require_once 'PHP/CodeCoverage/Filter.php'; -PHP_CodeCoverage_Filter::getInstance()->addFileToBlacklist(__FILE__, 'PHPUNIT'); +define('PHPUnit_MAIN_METHOD', 'PHPUnit_TextUI_Command::main'); if (strpos('@php_bin@', '@php_bin') === 0) { set_include_path(dirname(__FILE__) . PATH_SEPARATOR . get_include_path()); @@ -72,6 +71,4 @@ require_once 'PHPUnit/Autoload.php'; -define('PHPUnit_MAIN_METHOD', 'PHPUnit_TextUI_Command::main'); - PHPUnit_TextUI_Command::main();