/** * Test collect config, format var, order config */ public function testCollect() { $config = new Config(); $config->set('foo', 'bar'); $config->set('bar', 'foo'); $configDataCollector = new ConfigDataCollector($config); $dataFormatter = new DataFormatter(); $this->assertEquals(array('bar' => $dataFormatter->formatVar('foo'), 'foo' => $dataFormatter->formatVar('bar')), $configDataCollector->collect()); }
/** * @expectedException \InvalidArgumentException */ public function testNoValueException() { $this->config->offsetUnset('foo'); $this->config->get('foo'); }