mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
remove CAKE_TEST_LIB constant
This commit is contained in:
parent
998cba0759
commit
0508055ee9
5 changed files with 10 additions and 15 deletions
|
@ -75,6 +75,6 @@ if (Configure::read('debug') < 1) {
|
||||||
die(__d('cake', 'Debug setting does not allow access to this url.'));
|
die(__d('cake', 'Debug setting does not allow access to this url.'));
|
||||||
}
|
}
|
||||||
|
|
||||||
require_once CAKE_TESTS_LIB . 'CakeTestSuiteDispatcher.php';
|
require_once CAKE . 'TestSuite' . DS . 'CakeTestSuiteDispatcher.php';
|
||||||
|
|
||||||
CakeTestSuiteDispatcher::run();
|
CakeTestSuiteDispatcher::run();
|
||||||
|
|
|
@ -75,6 +75,6 @@ if (Configure::read('debug') < 1) {
|
||||||
die(__('Debug setting does not allow access to this url.'));
|
die(__('Debug setting does not allow access to this url.'));
|
||||||
}
|
}
|
||||||
|
|
||||||
require_once CAKE_TESTS_LIB . 'CakeTestSuiteDispatcher.php';
|
require_once CAKE . 'TestSuite' . DS . 'CakeTestSuiteDispatcher.php';
|
||||||
|
|
||||||
CakeTestSuiteDispatcher::run();
|
CakeTestSuiteDispatcher::run();
|
||||||
|
|
|
@ -123,7 +123,7 @@ class CakeTestSuiteDispatcher {
|
||||||
$found = $this->loadTestFramework();
|
$found = $this->loadTestFramework();
|
||||||
if (!$found) {
|
if (!$found) {
|
||||||
$baseDir = $this->_baseDir;
|
$baseDir = $this->_baseDir;
|
||||||
include CAKE_TESTS_LIB . 'templates/phpunit.php';
|
include CAKE . 'TestSuite' . DS . 'templates' . DS . 'phpunit.php';
|
||||||
exit();
|
exit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -166,7 +166,7 @@ class CakeTestSuiteDispatcher {
|
||||||
function _checkXdebug() {
|
function _checkXdebug() {
|
||||||
if (!extension_loaded('xdebug')) {
|
if (!extension_loaded('xdebug')) {
|
||||||
$baseDir = $this->_baseDir;
|
$baseDir = $this->_baseDir;
|
||||||
include CAKE_TESTS_LIB . 'templates/xdebug.php';
|
include CAKE . 'TestSuite' . DS . 'templates' . DS . 'xdebug.php';
|
||||||
exit();
|
exit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -238,7 +238,7 @@ class CakeTestSuiteDispatcher {
|
||||||
'baseUrl' => $this->_baseUrl,
|
'baseUrl' => $this->_baseUrl,
|
||||||
'baseDir' => $this->_baseDir,
|
'baseDir' => $this->_baseDir,
|
||||||
);
|
);
|
||||||
|
|
||||||
$options = array(
|
$options = array(
|
||||||
'--filter', $this->params['filter'],
|
'--filter', $this->params['filter'],
|
||||||
'--output', $this->params['output'],
|
'--output', $this->params['output'],
|
||||||
|
@ -252,7 +252,7 @@ class CakeTestSuiteDispatcher {
|
||||||
} catch (MissingConnectionException $exception) {
|
} catch (MissingConnectionException $exception) {
|
||||||
ob_end_clean();
|
ob_end_clean();
|
||||||
$baseDir = $this->_baseDir;
|
$baseDir = $this->_baseDir;
|
||||||
include CAKE_TESTS_LIB . 'templates' . DS . 'missing_connection.php';
|
include CAKE . 'TestSuite' . DS . 'templates' . DS . 'missing_connection.php';
|
||||||
exit();
|
exit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,7 +51,7 @@ class CakeHtmlReporter extends CakeBaseReporter {
|
||||||
public function paintDocumentStart() {
|
public function paintDocumentStart() {
|
||||||
ob_start();
|
ob_start();
|
||||||
$baseDir = $this->params['baseDir'];
|
$baseDir = $this->params['baseDir'];
|
||||||
include CAKE_TESTS_LIB . 'templates' . DS . 'header.php';
|
include CAKE . 'TestSuite' . DS . 'templates' . DS . 'header.php';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -64,7 +64,7 @@ class CakeHtmlReporter extends CakeBaseReporter {
|
||||||
$cases = $this->baseUrl() . '?show=cases';
|
$cases = $this->baseUrl() . '?show=cases';
|
||||||
$plugins = App::objects('plugin', null, false);
|
$plugins = App::objects('plugin', null, false);
|
||||||
sort($plugins);
|
sort($plugins);
|
||||||
include CAKE_TESTS_LIB . 'templates' . DS . 'menu.php';
|
include CAKE . 'TestSuite' . DS . 'templates' . DS . 'menu.php';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -212,7 +212,7 @@ class CakeHtmlReporter extends CakeBaseReporter {
|
||||||
*/
|
*/
|
||||||
public function paintDocumentEnd() {
|
public function paintDocumentEnd() {
|
||||||
$baseDir = $this->params['baseDir'];
|
$baseDir = $this->params['baseDir'];
|
||||||
include CAKE_TESTS_LIB . 'templates/footer.php';
|
include CAKE . 'TestSuite' . DS . 'templates' . DS . 'footer.php';
|
||||||
if (ob_get_length()) {
|
if (ob_get_length()) {
|
||||||
ob_end_flush();
|
ob_end_flush();
|
||||||
}
|
}
|
||||||
|
@ -343,4 +343,4 @@ class CakeHtmlReporter extends CakeBaseReporter {
|
||||||
}
|
}
|
||||||
echo '<h2>' . __d('cake_dev', 'Running %s', $suite->getName()) . '</h2>';
|
echo '<h2>' . __d('cake_dev', 'Running %s', $suite->getName()) . '</h2>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -94,11 +94,6 @@ if (!defined('CAKE_TESTS')) {
|
||||||
define('CAKE_TESTS', CAKE.'Test'.DS);
|
define('CAKE_TESTS', CAKE.'Test'.DS);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Path to the test suite.
|
|
||||||
*/
|
|
||||||
define('CAKE_TESTS_LIB', LIBS . 'TestSuite' . DS);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Path to the controller test directory.
|
* Path to the controller test directory.
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Reference in a new issue