@Test
public void testSequential() {
Properties properties = new Properties();
properties.setProperty( "drools.sequential", "false" );
RuleBaseConfiguration cfg = new RuleBaseConfiguration(properties);
assertFalse( cfg.isSequential() );
assertTrue( cfg.getAgendaGroupFactory() instanceof PriorityQueueAgendaGroupFactory );
properties = new Properties();
properties.setProperty( "drools.sequential.agenda", "sequential" );
properties.setProperty( "drools.sequential", "true" );
cfg = new RuleBaseConfiguration(properties);
assertTrue( cfg.isSequential() );
assertEquals( SequentialAgenda.SEQUENTIAL, cfg.getSequentialAgenda() );
properties = new Properties();
properties.setProperty( "drools.sequential.agenda", "dynamic" );
properties.setProperty( "drools.sequential", "true" );
cfg = new RuleBaseConfiguration(properties);
assertTrue( cfg.isSequential() );
assertEquals( SequentialAgenda.DYNAMIC, cfg.getSequentialAgenda() );
assertTrue( cfg.getAgendaGroupFactory() instanceof PriorityQueueAgendaGroupFactory );
}