assertNotNull( file );
file = mfs.getFile( KieBuilderImpl.getCompilationCachePath( releaseId, "KBase2") );
assertNotNull( file );
Resource jarRes = ks.getResources().newByteArrayResource( jar );
KieModule km = ks.getRepository().addKieModule( jarRes );
KieSession ksession = ks.newKieContainer( km.getReleaseId() ).newKieSession("KSession1");
ksession.insert(new Message("Hello World"));
assertEquals( 1, ksession.fireAllRules() );
ksession = ks.newKieContainer(km.getReleaseId()).newKieSession("KSession1");
ksession.insert(new Message("Hi Universe"));
assertEquals( 1, ksession.fireAllRules() );
ksession = ks.newKieContainer(km.getReleaseId()).newKieSession("KSession1");
ksession.insert(new Message("Aloha Earth"));
assertEquals( 0, ksession.fireAllRules() );
ksession = ks.newKieContainer(km.getReleaseId()).newKieSession("KSession2");
ksession.insert(new Message("Hello World"));
assertEquals( 1, ksession.fireAllRules() );
ksession = ks.newKieContainer(km.getReleaseId()).newKieSession("KSession2");
ksession.insert(new Message("Hi Universe"));
assertEquals( 0, ksession.fireAllRules() );
ksession = ks.newKieContainer(km.getReleaseId()).newKieSession("KSession2");
ksession.insert(new Message("Aloha Earth"));
assertEquals(1, ksession.fireAllRules());
}