@Override
protected Object createTest() throws Exception {
final BundleContext ctx = Activator.getBundleContext();
final ServiceReference ref = ctx.getServiceReference(TestObjectProcessor.class.getName());
final TestObjectProcessor top = ref == null ? null : (TestObjectProcessor)ctx.getService(ref);
if(top == null) {
log.info("No TestObjectProcessor service available, annotations will not be processed");
return super.createTest();
} else {
log.debug("Using TestObjectProcessor {}", top);
return top.process(super.createTest());
}
}