KieBaseConfiguration kbc = KnowledgeBaseFactory.newKnowledgeBaseConfiguration();
kbc.setOption( EqualityBehaviorOption.EQUALITY );
KnowledgeBase kbase = SerializationHelper.serializeObject( loadKnowledgeBase( kbc ) );
StatefulKnowledgeSession ksession = createKnowledgeSession( kbase );
CheeseEqual cheese = new CheeseEqual( "stilton",
10 );
ksession.insert( cheese );
org.kie.api.runtime.rule.FactHandle fh = ksession.getFactHandle( new CheeseEqual( "stilton",
10 ) );
assertNotNull( fh );
}