コード例 #1
0
 function __setupApp()
 {
     $config = new Config();
     $config->setProtected('basePath', BASE_PATH);
     setCommonConfig($config);
     setUniqueConfig($config);
     return new \App\Application($config);
 }
コード例 #2
0
 protected function setUp()
 {
     $config = new Config();
     $config->setProtected('basePath', BASE_PATH);
     setCommonConfig($config);
     setUniqueConfig($config);
     Application::setupRedBean('sqlite:test.db', 'user', 'password', $this->frozen, 'sqlite');
     R::freeze(false);
     R::nuke();
     R::freeze($this->frozen);
     $this->app = __setupApp();
     /** $http Mock Http object. */
     $http = $this->getMock('Skully\\Core\\Http');
     $http->expects($this->any())->method('redirect')->will($this->returnCallback('stubRedirect'));
     $this->app->setHttp($http);
 }
コード例 #3
0
ファイル: ConfigTest.php プロジェクト: skullyframework/skully
 public function testSetProtected()
 {
     $config = new Config();
     $config->setProtected('test', 'value');
     $this->assertEquals('value', $config->get('test'));
 }