// Create the test implementation factory
ModelFactoryExtensionPoint modelFactories = registry.getExtensionPoint(ModelFactoryExtensionPoint.class);
AssemblyFactory assemblyFactory = modelFactories.getFactory(AssemblyFactory.class);
JavaInterfaceFactory javaFactory = modelFactories.getFactory(JavaInterfaceFactory.class);
TestImplementationFactory testFactory = new DefaultTestImplementationFactory(assemblyFactory, javaFactory);
modelFactories.addFactory(testFactory);
// Add the test implementation extension to the StAXArtifactProcessor
// extension point
StAXArtifactProcessorExtensionPoint processors = registry.getExtensionPoint(StAXArtifactProcessorExtensionPoint.class);