当前位置: 首页>>代码示例>>PHP>>正文


PHP Solar_Test::setup方法代码示例

本文整理汇总了PHP中Solar_Test::setup方法的典型用法代码示例。如果您正苦于以下问题:PHP Solar_Test::setup方法的具体用法?PHP Solar_Test::setup怎么用?PHP Solar_Test::setup使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Solar_Test的用法示例。


在下文中一共展示了Solar_Test::setup方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     // remove "Test_" prefix
     $this->_class = substr(get_class($this), 5);
     $this->_access = Solar::factory($this->_class, $this->_config);
     parent::setup();
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:12,代码来源:Adapter.php

示例2: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     // var dumpers
     $this->_text = Solar::factory('Solar_Debug_Var', array('output' => 'text'));
     $this->_html = Solar::factory('Solar_Debug_Var', array('output' => 'html'));
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:12,代码来源:Var.php

示例3: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     // set up an SQL connection
     $this->_sql = Solar::factory('Solar_Sql', $this->_sql_config);
     // set up a model catalog
     $this->_catalog = Solar::factory('Solar_Sql_Model_Catalog', $this->_catalog_config);
     // register the connection and catalog
     Solar_Registry::set('sql', $this->_sql);
     Solar_Registry::set('model_catalog', $this->_catalog);
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:16,代码来源:Model.php

示例4: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     // when running from the command line, these elements are empty.
     // fake them so that web-like testing can occur.
     $_SERVER['HTTP_HOST'] = 'example.com';
     $_SERVER['SCRIPT_NAME'] = '/path/to/index.php';
     $_SERVER['PATH_INFO'] = '/appname/action';
     $_SERVER['QUERY_STRING'] = 'foo=bar&baz=dib';
     $_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'] . $_SERVER['PATH_INFO'] . '?' . $_SERVER['QUERY_STRING'];
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:16,代码来源:Uri.php

示例5: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     // set up an SQL connection
     $this->_sql = Solar::factory('Solar_Sql', $this->_sql_config);
     $this->_sql->setProfiling(true);
     // set up a model catalog
     $this->_catalog = Solar::factory('Solar_Sql_Model_Catalog', $this->_catalog_config);
     // register the connection and catalog
     Solar_Registry::set('sql', $this->_sql);
     Solar_Registry::set('model_catalog', $this->_catalog);
     // populate everything
     $this->_populateAll();
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:19,代码来源:Record.php

示例6: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     // set up an SQL connection
     $this->_sql = Solar::factory('Solar_Sql', $this->_sql_config);
     $this->_sql->setProfiling(true);
     // set up a model catalog
     $this->_catalog = Solar::factory('Solar_Sql_Model_Catalog', $this->_catalog_config);
     // register the connection and catalog
     Solar_Registry::set('sql', $this->_sql);
     Solar_Registry::set('model_catalog', $this->_catalog);
     // set the class name for relateds
     $len = strlen('Test_');
     $this->_class = substr(get_class($this), $len);
     // populate everything
     $this->_populateAll();
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:22,代码来源:Related.php

示例7: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:9,代码来源:Collection.php

示例8: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     Solar_Registry::set('sql', 'Solar_Sql');
     Solar_Registry::set('model_catalog', 'Solar_Sql_Model_Catalog');
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:11,代码来源:Model.php

示例9: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     Solar_Registry::set('sql', 'Solar_Sql');
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:10,代码来源:Select.php

示例10: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     $this->_page = Solar::factory($this->_page_class);
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:10,代码来源:Page.php

示例11: setup

 /**
  * 
  * Setup; runs before each test method.
  * 
  */
 public function setup()
 {
     parent::setup();
     $this->_session = Solar::factory('Solar_Session');
     $this->_session->setClass($this->_class);
 }
开发者ID:btweedy,项目名称:foresmo,代码行数:11,代码来源:Session.php


注:本文中的Solar_Test::setup方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。