public function testSetAndGetLogger() { $key = Registry::LOGGER; $object = new \StdClass(); Registry::set($key, $object); $actual = Registry::get($key); $this->assertEquals($object, $actual); $this->assertInstanceOf('StdClass', $actual); }
public function testSetAndGetLogger() { Registry::set(Registry::LOGGER, new \StdClass()); $logger = Registry::get(Registry::LOGGER); $this->assertInstanceOf('StdClass', $logger); }
/** * @expectedException \InvalidArgumentException */ public function testThrowsExceptionWhenTryingToSetInvalidKey() { Registry::set('foobar', new \stdClass()); }