Esempio n. 1
0
 function test_aliases()
 {
     self::$log = '';
     Analog::urgent('Testing');
     $this->assertStringMatchesFormat("localhost, %d-%d-%d %d:%d:%d, 0, Testing\n", self::$log);
     self::$log = '';
     Analog::alert('Testing');
     $this->assertStringMatchesFormat("localhost, %d-%d-%d %d:%d:%d, 1, Testing\n", self::$log);
     self::$log = '';
     Analog::error('Testing');
     $this->assertStringMatchesFormat("localhost, %d-%d-%d %d:%d:%d, 3, Testing\n", self::$log);
     self::$log = '';
     Analog::warning('Testing');
     $this->assertStringMatchesFormat("localhost, %d-%d-%d %d:%d:%d, 4, Testing\n", self::$log);
     self::$log = '';
     Analog::notice('Testing');
     $this->assertStringMatchesFormat("localhost, %d-%d-%d %d:%d:%d, 5, Testing\n", self::$log);
     self::$log = '';
     Analog::info('Testing');
     $this->assertStringMatchesFormat("localhost, %d-%d-%d %d:%d:%d, 6, Testing\n", self::$log);
     self::$log = '';
     Analog::debug('Testing');
     $this->assertStringMatchesFormat("localhost, %d-%d-%d %d:%d:%d, 7, Testing\n", self::$log);
     self::$log = '';
 }