Ejemplo n.º 1
0
 /**
  * Creates a schedule
  *
  * @ParamType("type", type="string")
  * @ParamType("expression", type="string")
  *
  * @param string $type
  * @param string $expression
  */
 public function createSchedule($type, $expression)
 {
     $this->job->addSchedule(ScheduleBuilder::create($type, $expression));
 }
Ejemplo n.º 2
0
 public function testCreate()
 {
     $schedule = ScheduleBuilder::create('cron', '* * * * *');
     $this->assertEquals('cron', $schedule->getType());
     $this->assertEquals('* * * * *', $schedule->getExpression());
 }