time() public method

Set time
public time ( string $time ) : self
$time string Time
return self This object
Example #1
0
 /**
  * Test: Set time
  *
  * @covers \Phue\Command\CreateSchedule::time
  */
 public function testTime()
 {
     $x = new CreateSchedule();
     $command = $x->time('2010-10-20T10:11:12');
     // Ensure property is set properly
     $this->assertAttributeInstanceOf('\\Phue\\TimePattern\\TimePatternInterface', 'time', $command);
     // Ensure self object is returned
     $this->assertEquals($command, $command->time('+10 seconds'));
 }