Logger = new Logger(); } /** * Cleans up the environment after running a test. */ protected function tearDown() { $this->Logger = null; parent::tearDown(); } /** * Tests Logger->__construct() */ public function test__construct() { $this->Logger->__construct(LOG_DEBUG); $this->assertEquals($this->Logger->debugLevel(), LOG_DEBUG); $this->Logger->__construct(LOG_EMERG - 1); $this->assertEquals($this->Logger->debugLevel(), LOG_EMERG); $this->Logger->__construct(LOG_DEBUG + 1); $this->assertEquals($this->Logger->debugLevel(), LOG_DEBUG); $this->Logger->__construct(); $this->assertEquals($this->Logger->debugLevel(), LOG_WARNING); } public function testDebugLevel() { $this->assertEquals(LOG_WARNING, $this->Logger->debugLevel()); $level = $this->Logger->debugLevel(LOG_EMERG); $this->assertEquals(LOG_WARNING, $level); $level = $this->Logger->debugLevel(); $this->assertEquals(LOG_EMERG, $level); } /** * Tests Logger->debug() */ public function testDebug() { $this->markTestSkipped("STDERR capture not available. Cannot test."); } }