mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Upgrade legacy uses of App::build() types
This commit is contained in:
parent
c4829dc3b8
commit
22582aee63
39 changed files with 81 additions and 81 deletions
|
@ -99,7 +99,7 @@ Cache::config('default', array('engine' => 'File'));
|
|||
* 'View/Helper' => array('/full/path/to/helpers/', '/next/full/path/to/helpers/'),
|
||||
* 'Vendor' => array('/full/path/to/vendors/', '/next/full/path/to/vendors/'),
|
||||
* 'Console/Command' => array('/full/path/to/shells/', '/next/full/path/to/shells/'),
|
||||
* 'locales' => array('/full/path/to/locale/', '/next/full/path/to/locale/')
|
||||
* 'Locale' => array('/full/path/to/locale/', '/next/full/path/to/locale/')
|
||||
* ));
|
||||
*
|
||||
*/
|
||||
|
|
|
@ -40,7 +40,7 @@ Cache::config('default', array('engine' => 'File'));
|
|||
* 'View/Helper' => array('/full/path/to/helpers/', '/next/full/path/to/helpers/'),
|
||||
* 'Vendor' => array('/full/path/to/vendors/', '/next/full/path/to/vendors/'),
|
||||
* 'Console/Command' => array('/full/path/to/shells/', '/next/full/path/to/shells/'),
|
||||
* 'locales' => array('/full/path/to/locale/', '/next/full/path/to/locale/')
|
||||
* 'Locale' => array('/full/path/to/locale/', '/next/full/path/to/locale/')
|
||||
* ));
|
||||
*
|
||||
*/
|
||||
|
|
|
@ -35,7 +35,7 @@ class BasicsTest extends CakeTestCase {
|
|||
*/
|
||||
public function setUp() {
|
||||
App::build(array(
|
||||
'locales' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS)
|
||||
'Locale' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS)
|
||||
));
|
||||
$this->_language = Configure::read('Config.language');
|
||||
}
|
||||
|
|
|
@ -87,7 +87,7 @@ class CacheTest extends CakeTestCase {
|
|||
public function testConfigWithLibAndPluginEngines() {
|
||||
App::build(array(
|
||||
'Lib' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Lib' . DS),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
@ -258,8 +258,8 @@ class CacheTest extends CakeTestCase {
|
|||
*/
|
||||
public function testDrop() {
|
||||
App::build(array(
|
||||
'libs' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Lib' . DS),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Lib' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Lib' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
|
||||
$result = Cache::drop('some_config_that_does_not_exist');
|
||||
|
@ -310,8 +310,8 @@ class CacheTest extends CakeTestCase {
|
|||
*/
|
||||
public function testWriteTriggerError() {
|
||||
App::build(array(
|
||||
'libs' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Lib' . DS),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Lib' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Lib' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
|
||||
Cache::config('test_trigger', array('engine' => 'TestAppCache', 'prefix' => ''));
|
||||
|
|
|
@ -84,7 +84,7 @@ class PhpReaderTest extends CakeTestCase {
|
|||
*/
|
||||
public function testReadPluginValue() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
$reader = new PhpReader($this->path);
|
||||
|
|
|
@ -40,7 +40,7 @@ class CommandListShellTest extends CakeTestCase {
|
|||
public function setUp() {
|
||||
parent::setUp();
|
||||
App::build(array(
|
||||
'plugins' => array(
|
||||
'Plugin' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS
|
||||
),
|
||||
'Console/Command' => array(
|
||||
|
|
|
@ -182,7 +182,7 @@ class SchemaShellTest extends CakeTestCase {
|
|||
*/
|
||||
public function testViewWithPlugins() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$this->Shell->args = array('TestPlugin.schema');
|
||||
|
@ -234,7 +234,7 @@ class SchemaShellTest extends CakeTestCase {
|
|||
*/
|
||||
public function testDumpFileWritingWithPlugins() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$this->Shell->args = array('TestPlugin.TestPluginApp');
|
||||
|
@ -335,7 +335,7 @@ class SchemaShellTest extends CakeTestCase {
|
|||
*/
|
||||
public function testGenerateWithPlugins() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
@ -450,7 +450,7 @@ class SchemaShellTest extends CakeTestCase {
|
|||
*/
|
||||
public function testPluginParam() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$this->Shell->params = array(
|
||||
|
@ -470,7 +470,7 @@ class SchemaShellTest extends CakeTestCase {
|
|||
*/
|
||||
public function testPluginDotSyntaxWithCreate() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$this->Shell->params = array(
|
||||
|
|
|
@ -225,7 +225,7 @@ class ExtractTaskTest extends CakeTestCase {
|
|||
*/
|
||||
public function testExtractExcludePlugins() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
$this->out = $this->getMock('ConsoleOutput', array(), array(), '', false);
|
||||
$this->in = $this->getMock('ConsoleInput', array(), array(), '', false);
|
||||
|
@ -251,7 +251,7 @@ class ExtractTaskTest extends CakeTestCase {
|
|||
*/
|
||||
public function testExtractPlugin() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
|
||||
$this->out = $this->getMock('ConsoleOutput', array(), array(), '', false);
|
||||
|
@ -279,7 +279,7 @@ class ExtractTaskTest extends CakeTestCase {
|
|||
public function testExtractModelValidation() {
|
||||
App::build(array(
|
||||
'Model' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
$this->out = $this->getMock('ConsoleOutput', array(), array(), '', false);
|
||||
$this->in = $this->getMock('ConsoleInput', array(), array(), '', false);
|
||||
|
@ -366,7 +366,7 @@ class ExtractTaskTest extends CakeTestCase {
|
|||
*/
|
||||
public function testExtractModelValidationInPlugin() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
$this->out = $this->getMock('ConsoleOutput', array(), array(), '', false);
|
||||
$this->in = $this->getMock('ConsoleInput', array(), array(), '', false);
|
||||
|
|
|
@ -572,7 +572,7 @@ class TestTaskTest extends CakeTestCase {
|
|||
public function testInteractiveWithPlugin() {
|
||||
$testApp = CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS;
|
||||
App::build(array(
|
||||
'plugins' => array($testApp)
|
||||
'Plugin' => array($testApp)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
|
|
@ -113,7 +113,7 @@ class ShellDispatcherTest extends CakeTestCase {
|
|||
public function setUp() {
|
||||
parent::setUp();
|
||||
App::build(array(
|
||||
'plugins' => array(
|
||||
'Plugin' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS
|
||||
),
|
||||
'Console/Command' => array(
|
||||
|
|
|
@ -171,8 +171,8 @@ class ShellTest extends CakeTestCase {
|
|||
*/
|
||||
public function testInitialize() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'models' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Model' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS)
|
||||
), App::RESET);
|
||||
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
|
|
@ -159,7 +159,7 @@ class FormAuthenticateTest extends CakeTestCase {
|
|||
public function testPluginModel() {
|
||||
Cache::delete('object_map', '_cake_core_');
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
|
|
@ -819,7 +819,7 @@ HTMLBLOC;
|
|||
|
||||
public function testPluginCustomViewClass() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
|
||||
|
|
|
@ -86,7 +86,7 @@ class ComponentCollectionTest extends CakeTestCase {
|
|||
$result = $this->Components->load('Cookie');
|
||||
$this->assertInstanceOf('CookieAliasComponent', $result);
|
||||
|
||||
App::build(array('plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
App::build(array('Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$result = $this->Components->load('SomeOther', array('className' => 'TestPlugin.Other'));
|
||||
$this->assertInstanceOf('OtherComponent', $result);
|
||||
|
@ -128,7 +128,7 @@ class ComponentCollectionTest extends CakeTestCase {
|
|||
*/
|
||||
public function testLoadPluginComponent() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$result = $this->Components->load('TestPlugin.Other');
|
||||
|
|
|
@ -219,7 +219,7 @@ class ComponentTest extends CakeTestCase {
|
|||
public function setUp() {
|
||||
$this->_pluginPaths = App::path('plugins');
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
}
|
||||
|
||||
|
|
|
@ -460,7 +460,7 @@ class ControllerTest extends CakeTestCase {
|
|||
*/
|
||||
public function testLoadModelInPlugins() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Controller' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Controller' . DS),
|
||||
'Model' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS)
|
||||
));
|
||||
|
@ -501,7 +501,7 @@ class ControllerTest extends CakeTestCase {
|
|||
|
||||
unset($Controller);
|
||||
|
||||
App::build(array('plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
App::build(array('Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
$Controller = new Controller($request);
|
||||
|
|
|
@ -32,7 +32,7 @@ class CakePluginTest extends CakeTestCase {
|
|||
*/
|
||||
public function setUp() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
App::objects('plugins', null, false);
|
||||
}
|
||||
|
|
|
@ -446,9 +446,9 @@ class ObjectTest extends CakeTestCase {
|
|||
*/
|
||||
public function testRequestAction() {
|
||||
App::build(array(
|
||||
'models' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS),
|
||||
'views' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View' . DS),
|
||||
'controllers' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Controller' . DS)
|
||||
'Model' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View' . DS),
|
||||
'Controller' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Controller' . DS)
|
||||
), App::RESET);
|
||||
$this->assertNull(Router::getRequest(), 'request stack should be empty.');
|
||||
|
||||
|
@ -488,7 +488,7 @@ class ObjectTest extends CakeTestCase {
|
|||
*/
|
||||
public function testRequestActionPlugins() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
Router::reload();
|
||||
|
@ -525,10 +525,10 @@ class ObjectTest extends CakeTestCase {
|
|||
*/
|
||||
public function testRequestActionArray() {
|
||||
App::build(array(
|
||||
'models' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS),
|
||||
'views' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View' . DS),
|
||||
'controllers' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Controller' . DS),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin'. DS)
|
||||
'Model' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View' . DS),
|
||||
'Controller' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Controller' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin'. DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load(array('TestPlugin'));
|
||||
|
||||
|
|
|
@ -229,7 +229,7 @@ class ErrorHandlerTest extends CakeTestCase {
|
|||
*/
|
||||
public function testLoadPluginHanlder() {
|
||||
App::build(array(
|
||||
'plugins' => array(
|
||||
'Plugin' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS
|
||||
)
|
||||
), App::RESET);
|
||||
|
|
|
@ -152,7 +152,7 @@ class ExceptionRendererTest extends CakeTestCase {
|
|||
public function setUp() {
|
||||
parent::setUp();
|
||||
App::build(array(
|
||||
'views' => array(
|
||||
'View' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS
|
||||
)
|
||||
), App::RESET);
|
||||
|
|
|
@ -33,8 +33,8 @@ class I18nTest extends CakeTestCase {
|
|||
public function setUp() {
|
||||
Cache::delete('object_map', '_cake_core_');
|
||||
App::build(array(
|
||||
'locales' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Locale' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load(array('TestPlugin'));
|
||||
}
|
||||
|
@ -2398,7 +2398,7 @@ class I18nTest extends CakeTestCase {
|
|||
*/
|
||||
public function testPluginTranslation() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
|
||||
Configure::write('Config.language', 'po');
|
||||
|
|
|
@ -47,8 +47,8 @@ class CakeLogTest extends CakeTestCase {
|
|||
*/
|
||||
public function testImportingLoggers() {
|
||||
App::build(array(
|
||||
'libs' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Lib' . DS),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Lib' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Lib' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
|
|
@ -451,7 +451,7 @@ class BehaviorCollectionTest extends CakeTestCase {
|
|||
$this->assertEquals($Apple->testMethod(true), 'working');
|
||||
$this->assertEquals($Apple->Behaviors->dispatchMethod($Apple, 'testMethod'), 'working');
|
||||
|
||||
App::build(array('plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
App::build(array('Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$this->assertTrue($Apple->Behaviors->load('SomeOther', array('className' => 'TestPlugin.TestPluginPersisterOne')));
|
||||
$this->assertInstanceOf('TestPluginPersisterOneBehavior', $Apple->Behaviors->SomeOther);
|
||||
|
|
|
@ -669,7 +669,7 @@ class CakeSchemaTest extends CakeTestCase {
|
|||
public function testSchemaReadWithPlugins() {
|
||||
App::objects('model', null, false);
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
@ -982,7 +982,7 @@ class CakeSchemaTest extends CakeTestCase {
|
|||
*/
|
||||
public function testSchemaLoadingFromPlugin() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$Other = $this->Schema->load(array('name' => 'TestPluginApp', 'plugin' => 'TestPlugin'));
|
||||
|
|
|
@ -88,7 +88,7 @@ class ConnectionManagerTest extends CakeTestCase {
|
|||
*/
|
||||
public function testGetPluginDataSource() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
$name = 'test_source';
|
||||
|
@ -109,7 +109,7 @@ class ConnectionManagerTest extends CakeTestCase {
|
|||
*/
|
||||
public function testGetPluginDataSourceAndPluginDriver() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
$name = 'test_plugin_source_and_driver';
|
||||
|
@ -132,7 +132,7 @@ class ConnectionManagerTest extends CakeTestCase {
|
|||
*/
|
||||
public function testGetLocalDataSourceAndPluginDriver() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$name = 'test_local_source_and_plugin_driver';
|
||||
|
@ -154,7 +154,7 @@ class ConnectionManagerTest extends CakeTestCase {
|
|||
*/
|
||||
public function testGetPluginDataSourceAndLocalDriver() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Model/Datasource/Database' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS . 'Datasource' . DS . 'Database' . DS
|
||||
)
|
||||
|
@ -270,7 +270,7 @@ class ConnectionManagerTest extends CakeTestCase {
|
|||
*/
|
||||
public function testConnectionData() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Model/Datasource' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS . 'Datasource' . DS
|
||||
)
|
||||
|
|
|
@ -503,7 +503,7 @@ class CakeSessionTest extends CakeTestCase {
|
|||
'Model/Datasource/Session' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS . 'Datasource' . DS . 'Session' . DS
|
||||
),
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
Configure::write('Session', array(
|
||||
'defaults' => 'cake',
|
||||
|
@ -524,7 +524,7 @@ class CakeSessionTest extends CakeTestCase {
|
|||
*/
|
||||
public function testUsingPluginHandler() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
|
|
@ -368,7 +368,7 @@ class AclNodeTest extends CakeTestCase {
|
|||
*/
|
||||
public function testNodeActionAuthorize() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
|
|
@ -110,7 +110,7 @@ class CakeEmailTest extends CakeTestCase {
|
|||
$this->CakeEmail = new TestCakeEmail();
|
||||
|
||||
App::build(array(
|
||||
'views' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
}
|
||||
|
||||
|
@ -1036,7 +1036,7 @@ class CakeEmailTest extends CakeTestCase {
|
|||
*/
|
||||
public function testSendRenderPlugin() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
|
||||
|
|
|
@ -1037,7 +1037,7 @@ class DispatcherTest extends CakeTestCase {
|
|||
|
||||
Router::reload();
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load(array('TestPlugin', 'TestPluginTwo'));
|
||||
|
||||
|
@ -1113,7 +1113,7 @@ class DispatcherTest extends CakeTestCase {
|
|||
public function testTestPluginDispatch() {
|
||||
$Dispatcher = new TestDispatcher();
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load(array('TestPlugin', 'TestPluginTwo'));
|
||||
Router::reload();
|
||||
|
@ -1172,8 +1172,8 @@ class DispatcherTest extends CakeTestCase {
|
|||
Router::reload();
|
||||
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'vendors' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Vendor'. DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Vendor' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Vendor'. DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
CakePlugin::load(array('TestPlugin', 'TestPluginTwo'));
|
||||
|
|
|
@ -133,7 +133,7 @@ class RouterTest extends CakeTestCase {
|
|||
*/
|
||||
public function testPluginMapResources() {
|
||||
App::build(array(
|
||||
'plugins' => array(
|
||||
'Plugin' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS
|
||||
)
|
||||
));
|
||||
|
@ -173,7 +173,7 @@ class RouterTest extends CakeTestCase {
|
|||
*/
|
||||
public function testPluginMapResourcesWithPrefix() {
|
||||
App::build(array(
|
||||
'plugins' => array(
|
||||
'Plugin' => array(
|
||||
CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS
|
||||
)
|
||||
));
|
||||
|
|
|
@ -120,7 +120,7 @@ class ControllerTestCaseTest extends CakeTestCase {
|
|||
public function setUp() {
|
||||
parent::setUp();
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Controller' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Controller' . DS),
|
||||
'Model' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Model' . DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View' . DS)
|
||||
|
|
|
@ -29,7 +29,7 @@ class HtmlCoverageReportTest extends CakeTestCase {
|
|||
public function setUp() {
|
||||
parent::setUp();
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
), App::RESET);
|
||||
CakePlugin::load(array('TestPlugin'));
|
||||
$reporter = new CakeBaseReporter();
|
||||
|
|
|
@ -655,7 +655,7 @@ class CakeTimeTest extends CakeTestCase {
|
|||
*/
|
||||
public function testConvertSpecifiers() {
|
||||
App::build(array(
|
||||
'locales' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS)
|
||||
'Locale' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS)
|
||||
), App::RESET);
|
||||
Configure::write('Config.language', 'time_test');
|
||||
$time = strtotime('Thu Jan 14 11:43:39 2010');
|
||||
|
@ -762,7 +762,7 @@ class CakeTimeTest extends CakeTestCase {
|
|||
*/
|
||||
public function testI18nFormat() {
|
||||
App::build(array(
|
||||
'locales' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS)
|
||||
'Locale' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Locale' . DS)
|
||||
), App::RESET);
|
||||
Configure::write('Config.language', 'time_test');
|
||||
|
||||
|
|
|
@ -7759,7 +7759,7 @@ class FormHelperTest extends CakeTestCase {
|
|||
public function testIntrospectModelFromRequest() {
|
||||
$this->loadFixtures('Post');
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)
|
||||
));
|
||||
CakePlugin::load('TestPlugin');
|
||||
$this->Form->request['models'] = array('TestPluginPost' => array('plugin' => 'TestPlugin', 'className' => 'TestPluginPost'));
|
||||
|
|
|
@ -150,7 +150,7 @@ class HtmlHelperTest extends CakeTestCase {
|
|||
$this->Html->request->webroot = '';
|
||||
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin'. DS)
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin'. DS)
|
||||
));
|
||||
|
||||
Configure::write('Asset.timestamp', false);
|
||||
|
@ -404,7 +404,7 @@ class HtmlHelperTest extends CakeTestCase {
|
|||
$File = new File($testfile, true);
|
||||
|
||||
App::build(array(
|
||||
'views' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
Configure::write('Asset.timestamp', true);
|
||||
Configure::write('debug', 1);
|
||||
|
@ -442,7 +442,7 @@ class HtmlHelperTest extends CakeTestCase {
|
|||
*/
|
||||
public function testThemeAssetsInMainWebrootPath() {
|
||||
App::build(array(
|
||||
'views' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
$webRoot = Configure::read('App.www_root');
|
||||
Configure::write('App.www_root', CAKE . 'Test' . DS . 'test_app' . DS . 'webroot' . DS);
|
||||
|
@ -933,7 +933,7 @@ class HtmlHelperTest extends CakeTestCase {
|
|||
$File = new File($testfile, true);
|
||||
|
||||
App::build(array(
|
||||
'views' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
|
||||
$this->Html->webroot = '/';
|
||||
|
|
|
@ -84,7 +84,7 @@ class HelperCollectionTest extends CakeTestCase {
|
|||
$result = $this->Helpers->load('Html');
|
||||
$this->assertInstanceOf('HtmlAliasHelper', $result);
|
||||
|
||||
App::build(array('plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
App::build(array('Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)));
|
||||
CakePlugin::load(array('TestPlugin'));
|
||||
$result = $this->Helpers->load('SomeOther', array('className' => 'TestPlugin.OtherHelper'));
|
||||
$this->assertInstanceOf('OtherHelperHelper', $result);
|
||||
|
@ -125,7 +125,7 @@ class HelperCollectionTest extends CakeTestCase {
|
|||
*/
|
||||
public function testLoadPluginHelper() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
));
|
||||
CakePlugin::load(array('TestPlugin'));
|
||||
$result = $this->Helpers->load('TestPlugin.OtherHelper');
|
||||
|
|
|
@ -200,7 +200,7 @@ class HelperTest extends CakeTestCase {
|
|||
ClassRegistry::addObject('HelperTestTag', new HelperTestTag());
|
||||
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
));
|
||||
}
|
||||
|
||||
|
@ -886,7 +886,7 @@ class HelperTest extends CakeTestCase {
|
|||
*/
|
||||
public function testLazyLoadingHelpers() {
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
));
|
||||
CakePlugin::load(array('TestPlugin'));
|
||||
$Helper = new TestHelper($this->View);
|
||||
|
|
|
@ -111,7 +111,7 @@ class ThemeViewTest extends CakeTestCase {
|
|||
$this->PostsController->index();
|
||||
$this->ThemeView = new ThemeView($this->PostsController);
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
App::objects('plugins', null, false);
|
||||
|
|
|
@ -269,7 +269,7 @@ class ViewTest extends CakeTestCase {
|
|||
$this->ThemeView = new View($this->ThemePostsController);
|
||||
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
), App::RESET);
|
||||
App::objects('plugins', null, false);
|
||||
|
@ -420,7 +420,7 @@ class ViewTest extends CakeTestCase {
|
|||
|
||||
$View = new TestView($this->Controller);
|
||||
App::build(array(
|
||||
'plugins' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'Plugin' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS),
|
||||
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View'. DS)
|
||||
));
|
||||
|
||||
|
|
Loading…
Reference in a new issue