private KieSession ksession;
public void init() {
final KieServices ks = KieServices.Factory.get();
KieFileSystem kfs = ks.newKieFileSystem();
KieModuleModel kmodule = ks.newKieModuleModel();
KieBaseModel baseModel = kmodule.newKieBaseModel( "defaultKBase" ).setDefault( true );
baseModel.newKieSessionModel( "defaultKSession" ).setDefault( true );
kfs.writeKModuleXML( kmodule.toXML() );
kfs.write( ks.getResources().newClassPathResource( "decimalSeparator.xls",
this.getClass() ) ); // README when path is set then test works
KieBuilder kieBuilder = ks.newKieBuilder( kfs ).buildAll();
assertEquals( 0,
kieBuilder.getResults().getMessages( org.kie.api.builder.Message.Level.ERROR ).size() );