use of org.drools.testcoverage.common.util.KieBaseTestConfiguration in project drools by kiegroup.
the class GuidedDecisionTableTest method initKieSession.
private void initKieSession(String... resourceNames) {
KieResources kieResources = KieServices.get().getResources();
final Resource[] resources = Stream.of(resourceNames).map(resource -> kieResources.newClassPathResource(resource, GuidedDecisionTableTest.class)).toArray(Resource[]::new);
final KieBase kBase = KieBaseUtil.getKieBaseFromResources(kieBaseTestConfiguration, resources);
kSession = kBase.newKieSession();
rulesFired = new TrackingAgendaEventListener();
kSession.addEventListener(rulesFired);
rulesFired.clear();
}
Aggregations