use of org.drools.core.meta.org.test.SubKlass_ in project drools by kiegroup.
the class MetadataTest method testKlassAndSubKlassWithImpl.
@Test
public void testKlassAndSubKlassWithImpl() {
SubKlass ski = new SubKlassImpl();
ski.setSubProp(42);
ski.setProp("hello");
SubKlass_ sk = new SubKlass_(ski);
assertEquals(42, (int) sk.subProp.get(ski));
assertEquals("hello", sk.prop.get(ski));
sk.modify().prop("bye").subProp(-99).call();
assertEquals(-99, (int) sk.subProp.get(ski));
assertEquals("bye", sk.prop.get(ski));
}
Aggregations