/**
  * Tests the JApplicationCli::get method.
  *
  * @return  void
  *
  * @since   11.3
  */
 public function testGet()
 {
     $config = new JRegistry(array('foo' => 'bar'));
     TestReflection::getValue($this->class, 'config', $config);
     $this->assertEquals('bar', $this->class->get('foo', 'bar'), 'Checks a known configuration setting is returned.');
     $this->assertEquals('car', $this->class->get('goo', 'car'), 'Checks an unknown configuration setting returns the default.');
 }
Esempio n. 2
0
 /**
  * Tests the JApplicationCli::get method.
  *
  * @return  void
  *
  * @since   11.3
  */
 public function testGet()
 {
     $config = new JRegistry(array('foo' => 'bar'));
     $this->inspector->setClassProperty('config', $config);
     $this->assertThat($this->inspector->get('foo', 'car'), $this->equalTo('bar'), 'Checks a known configuration setting is returned.');
     $this->assertThat($this->inspector->get('goo', 'car'), $this->equalTo('car'), 'Checks an unknown configuration setting returns the default.');
 }
Esempio n. 3
0
 /**
  * Tests the JApplicationCli::get method.
  *
  * @return  void
  *
  * @since   11.3
  */
 public function testGet()
 {
     $this->assertEquals('bar', $this->class->get('foo', 'bar'), 'Checks a known configuration setting is returned.');
     $this->assertEquals('car', $this->class->get('goo', 'car'), 'Checks an unknown configuration setting returns the default.');
 }