jobTrigger.setMinuteRecurrence( startingMinute );
jobTrigger.setSecondRecurrence( recurrenceList );
System.out.println( jobTrigger.toString() );
String jobName = "complexJob1";
Job job = scheduler.createJob( jobName, TestAction.class, new HashMap<String, Serializable>(), jobTrigger );
Assert.assertTrue( job.getJobName().contains( jobName ) );
Assert.assertEquals( job.getSchedulableClass(), TestAction.class.getName() );
Assert.assertEquals( job.getJobTrigger().toString(), jobTrigger.toString() );
jobTrigger.setSecondRecurrence( sequentialRecurrence );
jobName = "complexJob2";
job = scheduler.createJob( jobName, TestAction2.class, new HashMap<String, Serializable>(), jobTrigger );
Assert.assertTrue( job.getJobName().contains( jobName ) );
Assert.assertEquals( job.getSchedulableClass(), TestAction2.class.getName() );
Assert.assertEquals( job.getJobTrigger().toString(), jobTrigger.toString() );
jobTrigger.setSecondRecurrence( incrementalRecurrence );
jobName = "complexJob3";
job = scheduler.createJob( jobName, TestAction3.class, new HashMap<String, Serializable>(), jobTrigger );
Assert.assertTrue( job.getJobName().contains( jobName ) );
Assert.assertEquals( job.getSchedulableClass(), TestAction3.class.getName() );
Assert.assertEquals( job.getJobTrigger().toString(), jobTrigger.toString() );
//
// Wait for the jobs to complete, then check that each action executed the correct number of times
//
sleep( 60 );