Пример #1
0
 public function testSetLogger()
 {
     $logger = 'the logger';
     try {
         $this->object->setLogger($logger);
         $this->fail('setLogger do not accept string argument!');
     } catch (Phigrate_Exception_Argument $ex) {
         $msg = 'Logger parameter must be instance of Phigrate_Logger';
         $this->assertEquals($msg, $ex->getMessage());
     }
     $logger = $this->object->getLogger();
     $actual = $this->object->setLogger($logger);
     $this->assertInstanceOf('Phigrate_Adapter_Mysql_Adapter', $actual);
 }