KieFileSystem kfs = ks.newKieFileSystem()
.write( "src/main/resources/dsl.dsl", dsl1 )
.write( "src/main/resources/drl.dslr", drl1 );
KieBuilder kieBuilder = ks.newKieBuilder( kfs ).buildAll();
Results fullBuildResults = kieBuilder.getResults();
assertEquals( 3,
fullBuildResults.getMessages().size() );
kfs.write( "src/main/resources/r2.drl", drl2 );
IncrementalResults incrementalBuildResults = ( (InternalKieBuilder) kieBuilder ).createFileSet( "src/main/resources/r2.drl" ).build();
assertEquals( 0, incrementalBuildResults.getAddedMessages().size() );