Browse files

Fix test failures

git-svn-id: https://svn.apache.org/repos/asf/aries/trunk@1421160 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information...
1 parent 3e11f4a commit fe68bf125d6c6a756e43e37ed85d936112d49ced @gnodet gnodet committed Dec 13, 2012
View
4 ...print-core/src/main/java/org/apache/aries/blueprint/container/BlueprintContainerImpl.java
@@ -159,14 +159,14 @@ public BlueprintContainerImpl(BundleContext bundleContext, Bundle extenderBundle
NamespaceHandlerRegistry handlers, ExecutorService executor, ScheduledExecutorService timer,
List<Object> pathList, ProxyManager proxyManager) {
this.bundleContext = bundleContext;
- this.bundle = bundleContext.getBundle();
+ this.bundle = bundleContext != null ? bundleContext.getBundle() : null;
this.extenderBundle = extenderBundle;
this.eventDispatcher = eventDispatcher;
this.handlers = handlers;
this.pathList = pathList;
this.converter = new AggregateConverter(this);
this.componentDefinitionRegistry = new ComponentDefinitionRegistryImpl();
- this.executors = new ExecutorServiceWrapper(executor);
+ this.executors = executor != null ? new ExecutorServiceWrapper(executor) : null;
this.timer = timer;
this.processors = new ArrayList<Processor>();
if (System.getSecurityManager() != null) {
View
2 ...print/blueprint-core/src/test/java/org/apache/aries/blueprint/TestBlueprintContainer.java
@@ -44,7 +44,7 @@ public TestBlueprintContainer(ComponentDefinitionRegistryImpl registry) throws E
}
public TestBlueprintContainer(ComponentDefinitionRegistryImpl registry, ProxyManager proxyManager) throws Exception {
- super(new TestBundleContext(), null, null, null, null, null, proxyManager);
+ super(new TestBundleContext(), null, null, null, null, null, null, proxyManager);
this.registry = registry;
if (registry != null) {
registry.registerComponentDefinition(new PassThroughMetadataImpl("blueprintContainer", this));
View
4 ...int/blueprint-core/src/test/java/org/apache/aries/blueprint/container/BeanRecipeTest.java
@@ -120,7 +120,7 @@ public void init() {
@Test
public void parameterWithGenerics() throws Exception {
- BlueprintContainerImpl container = new BlueprintContainerImpl(null, null, null, null, null, null, null);
+ BlueprintContainerImpl container = new BlueprintContainerImpl(null, null, null, null, null, null, null, null);
BeanRecipe recipe = new BeanRecipe("example", container, ExampleService.class, false);
recipe.setArguments(Arrays.<Object>asList(new ExampleImpl()));
recipe.setArgTypes(Arrays.<String>asList((String) null));
@@ -195,7 +195,7 @@ public void baseTypeHiding() throws Exception {
@Test
public void protectedClassAccess() throws Exception {
- BlueprintContainerImpl container = new BlueprintContainerImpl(null, null, null, null, null, null, null);
+ BlueprintContainerImpl container = new BlueprintContainerImpl(null, null, null, null, null, null, null, null);
BeanRecipe recipe = new BeanRecipe("a", container, null, false);
recipe.setFactoryComponent(new PassThroughRecipe("factory", new Factory().create()));
recipe.setFactoryMethod("getA");

0 comments on commit fe68bf1

Please sign in to comment.