コード例 #1
0
 public function testSetValueNullRemovesKey()
 {
     $default = 'default';
     $this->mockValue = null;
     $this->setMockWriteExpectation($this->once());
     $this->config->set($this->key, $this->mockValue);
     $value = $this->config->get($this->key, $default);
     $this->assertEquals($default, $value);
 }
コード例 #2
0
ファイル: Zibo.php プロジェクト: BGCX261/zibo-svn-to-git
 /**
  * Get a configuration value
  * @param string $key key of the configuration value
  * @param mixed $default default value for when the configuration value is not set
  * @return mixed the configuration value or the provided default value when the configuration value is set
  */
 public function getConfigValue($key, $default = null)
 {
     return $this->config->get($key, $default);
 }