當前位置: 首頁>>代碼示例>>PHP>>正文


PHP CroogoTestCase::setUp方法代碼示例

本文整理匯總了PHP中CroogoTestCase::setUp方法的典型用法代碼示例。如果您正苦於以下問題:PHP CroogoTestCase::setUp方法的具體用法?PHP CroogoTestCase::setUp怎麽用?PHP CroogoTestCase::setUp使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在CroogoTestCase的用法示例。


在下文中一共展示了CroogoTestCase::setUp方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: setUp

 public function setUp()
 {
     parent::setUp();
     App::build(array('Plugin' => array(CakePlugin::path('Extensions') . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS)), App::PREPEND);
     $this->CroogoPlugin = $this->getMock('CroogoPlugin', array('_writeSetting', 'needMigration'));
     $this->_mapping = array(1346748762 => array('version' => 1346748762, 'name' => '1346748762_first', 'class' => 'First', 'type' => 'app', 'migrated' => '2012-09-04 10:52:42'), 1346748933 => array('version' => 1346748933, 'name' => '1346748933_addstatus', 'class' => 'AddStatus', 'type' => 'app', 'migrated' => '2012-09-04 10:55:33'));
 }
開發者ID:Demired,項目名稱:CakeWX,代碼行數:7,代碼來源:CroogoPluginTest.php

示例2: setUp

 /**
  * setUp method
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $Folder = new Folder(APP . 'Plugin' . DS . 'Example');
     $Folder->copy(TESTS . 'test_app' . DS . 'Plugin' . DS . 'Example');
     $this->Setting = ClassRegistry::init('Settings.Setting');
 }
開發者ID:laiello,項目名稱:plankonindia,代碼行數:12,代碼來源:ExtShellTest.php

示例3: setUp

 public function setUp()
 {
     parent::setUp();
     $this->View = new View(null);
     $this->AppHelper = new AppHelper($this->View);
     $this->AppHelper->request = new CakeRequest(null, false);
 }
開發者ID:romaing,項目名稱:croogo-rg,代碼行數:7,代碼來源:AppHelperTest.php

示例4: setUp

 public function setUp()
 {
     $this->FileManager = new FileManager(false, null, null, null);
     $this->__testAppPath = CakePlugin::path('FileManager') . 'Test' . DS . 'test_app' . DS;
     $this->__setFilePathsForTests();
     parent::setUp();
 }
開發者ID:saydulk,項目名稱:croogo,代碼行數:7,代碼來源:FileManagerTest.php

示例5: setUp

 /**
  * setUp method
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $Folder = new Folder(APP . 'Plugin' . DS . 'Example');
     $Folder->copy(CakePlugin::path('Croogo') . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS . 'Example');
     $this->Setting = ClassRegistry::init('Settings.Setting');
 }
開發者ID:Demired,項目名稱:CakeWX,代碼行數:12,代碼來源:ExtShellTest.php

示例6: setUp

 public function setUp()
 {
     parent::setUp();
     $this->loadFixtures('Trackable');
     $this->model = ClassRegistry::init(array('class' => 'TestModel', 'alias' => 'TestModel', 'table' => 'trackables'));
     $this->model->Behaviors->attach('Croogo.Trackable');
 }
開發者ID:saydulk,項目名稱:croogo,代碼行數:7,代碼來源:TrackableBehaviorTest.php

示例7: setUp

 public function setUp()
 {
     parent::setUp();
     $this->_level = Configure::read('Comment.level');
     Configure::write('Comment.level', 10);
     $this->Comment = ClassRegistry::init('Comments.Comment');
     $this->_record = $this->Comment->findById(1);
 }
開發者ID:saydulk,項目名稱:croogo,代碼行數:8,代碼來源:CommentTest.php

示例8: setUp

 /**
  * setUp
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $this->OrderRecord = ClassRegistry::init('OrderRecord');
     $this->OrderRecord->Behaviors->attach('Ordered', array('field' => 'weight', 'foreign_key' => null));
     $this->defaultPrefix = Configure::read('Cache.defaultPrefix');
     $this->Block = ClassRegistry::init('Blocks.Block');
 }
開發者ID:saydulk,項目名稱:croogo,代碼行數:13,代碼來源:OrderedBehaviorTest.php

示例9: setUp

 /**
  * setUp
  */
 public function setUp()
 {
     parent::setUp();
     $request = $this->getMock('CakeRequest');
     $response = $this->getMock('CakeResponse');
     $this->View = new View(new TheNodesTestController($request, $response));
     $this->Nodes = new NodesHelper($this->View);
 }
開發者ID:Demired,項目名稱:CakeWX,代碼行數:11,代碼來源:NodesHelperTest.php

示例10: setUp

 /**
  * setUp
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $this->User = ClassRegistry::init('Users.User');
     $this->User->Behaviors->unload('Acl');
     $this->User->Behaviors->unload('Searchable');
     $this->defaultPrefix = Configure::read('Cache.defaultPrefix');
 }
開發者ID:saydulk,項目名稱:croogo,代碼行數:13,代碼來源:CachedBehaviorTest.php

示例11: setUp

 public function setUp()
 {
     parent::setUp();
     CakePlugin::load('Translate');
     $this->View = new View(null);
     $this->AppHelper = new CroogoAppHelper($this->View);
     $this->AppHelper->request = new CakeRequest(null, false);
 }
開發者ID:saydulk,項目名稱:croogo,代碼行數:8,代碼來源:CroogoAppHelperTest.php

示例12: setUp

 public function setUp()
 {
     parent::setUp();
     CakePlugin::load('Translate', array('bootstrap' => true));
     $this->View = new View(null);
     $this->AppHelper = new AppHelper($this->View);
     $this->AppHelper->request = new CakeRequest(null, false);
 }
開發者ID:laiello,項目名稱:plankonindia,代碼行數:8,代碼來源:AppHelperTest.php

示例13: setUp

 /**
  * setUp
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $this->Node = ClassRegistry::init('Nodes.Node');
     if (!CakePlugin::loaded('Translate')) {
         CakePlugin::load('Translate');
     }
     $this->Node->Behaviors->attach('Translate.CroogoTranslate', array('fields' => array('title' => 'titleTranslation')));
 }
開發者ID:saydulk,項目名稱:croogo,代碼行數:14,代碼來源:CroogoTranslateBehaviorTest.php

示例14: setUp

 /**
  * setUp
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     App::build(array('Plugin' => array(CakePlugin::path('Extensions') . 'Test' . DS . 'test_app' . DS . 'Plugin' . DS), 'View' => array(CakePlugin::path('Extensions') . 'Test' . DS . 'test_app' . DS . 'View' . DS)), App::PREPEND);
     $this->testPlugin = CakePlugin::path('Extensions') . 'Test' . DS . 'test_files' . DS . 'example_plugin.zip';
     $this->testTheme = CakePlugin::path('Extensions') . 'Test' . DS . 'test_files' . DS . 'example_theme.zip';
     $this->CroogoComposer = new CroogoComposer();
     $this->CroogoComposer->appPath = CakePlugin::path('Extensions') . 'Test' . DS . 'test_app' . DS;
 }
開發者ID:dlpc,項目名稱:CakeWX,代碼行數:14,代碼來源:CroogoComposerTest.php

示例15: setUp

 /**
  * setUp
  */
 public function setUp()
 {
     parent::setUp();
     $this->ComponentCollection = new ComponentCollection();
     $request = $this->getMock('CakeRequest');
     $response = $this->getMock('CakeResponse');
     $this->View = new View(new TheTaxonomyTestController($request, $response));
     $this->Taxonomies = new TaxonomiesHelper($this->View);
 }
開發者ID:dlpc,項目名稱:CakeWX,代碼行數:12,代碼來源:TaxonomiesHelperTest.php


注:本文中的CroogoTestCase::setUp方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。