@Override public synchronized void start(StartContext context) throws StartException { serviceTarget = context.getChildTarget(); arqService.registerArquillianConfig(this); for (String testClass : testClasses) { ServiceTargetAssociation.setServiceTarget(testClass, serviceTarget); } }
Class<?> loadClass(String className) throws ClassNotFoundException { if (testClasses.contains(className) == false) throw new ClassNotFoundException("Class '" + className + "' not found in: " + testClasses); Module module = depUnit.getAttachment(Attachments.MODULE); BundleAssociation.setBundle(getAssociatedBundle(module)); Class<?> testClass = module.getClassLoader().loadClass(className); ServiceTargetAssociation.setServiceTarget(serviceTarget); return testClass; }