assertNotContains( wm6, this.ruleBase.getStatefulSessions() );
}
public void testAddPackage() throws Exception {
final org.drools.rule.Package pkg1 = new org.drools.rule.Package( "org.droos.test" );
pkg1.setClassFieldAccessorCache( new ClassFieldAccessorCache( Thread.currentThread().getContextClassLoader() ) );
pkg1.addGlobal( "global1",
Object.class );
pkg1.addGlobal( "global2",
Object.class );
final org.drools.rule.Package pkg2 = new org.drools.rule.Package( "org.droos.test" );
pkg2.setClassFieldAccessorCache( new ClassFieldAccessorCache( Thread.currentThread().getContextClassLoader() ) );
pkg2.addGlobal( "global1",
Object.class );
pkg2.addGlobal( "global3",
Object.class );
final org.drools.rule.Package pkg3 = new org.drools.rule.Package( "org.droos.test2" );
pkg3.setClassFieldAccessorCache( new ClassFieldAccessorCache( Thread.currentThread().getContextClassLoader() ) );
pkg3.addGlobal( "global3",
Object.class );
pkg3.addGlobal( "global4",
Object.class );