Esempio n. 1
0
 /**
  * Test marking a none existing timeserver as current
  *
  * @return void
  */
 public function testSetUnknownCurrent()
 {
     $server = new TimeSync\TimeSync();
     $this->setExpectedException('Zend\\TimeSync\\Exception\\InvalidArgumentException');
     $server->setServer('unkown_alias');
 }
Esempio n. 2
0
 /**
  * Test marking a none existing timeserver as current
  *
  * @return void
  */
 public function testSetUnknownCurrent()
 {
     $server = new TimeSync\TimeSync();
     try {
         $server->setServer('unkown_alias');
         $this->fail('Exception expected because there is no timeserver which we can mark as current');
     } catch (TimeSync\Exception $e) {
         // success
     }
 }