X-Git-Url: http://wamblee.org/gitweb/?a=blobdiff_plain;f=system%2Fgeneral%2Fsrc%2Ftest%2Fjava%2Forg%2Fwamblee%2Fsystem%2Fcontainer%2FContainerTest.java;h=2721c5115ec7289747112407214e9620f310c9bc;hb=96c8961955a306314dfe0cf9ca192252de39fc1c;hp=25ec9bc231582572134759715b374889ba1d8e94;hpb=539c6d91b7a34e32c6669445d00e9275c337530a;p=utils diff --git a/system/general/src/test/java/org/wamblee/system/container/ContainerTest.java b/system/general/src/test/java/org/wamblee/system/container/ContainerTest.java index 25ec9bc2..2721c511 100644 --- a/system/general/src/test/java/org/wamblee/system/container/ContainerTest.java +++ b/system/general/src/test/java/org/wamblee/system/container/ContainerTest.java @@ -1,22 +1,23 @@ /* - * Copyright 2007 the original author or authors. - * + * Copyright 2005-2010 the original author or authors. + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ + */ package org.wamblee.system.container; import junit.framework.TestCase; +import org.junit.internal.requests.IgnoredClassRunner; import org.wamblee.general.Pair; import org.wamblee.system.core.Component; @@ -222,12 +223,19 @@ public class ContainerTest extends TestCase { Component comp = new Application(); Container system = new Container("top").addComponent(comp); Container system2 = new Container("top2").addComponent(comp); + + ignoredVariable(system); + ignoredVariable(system2); } catch (SystemAssemblyException e) { return; } fail(); } + + private static void ignoredVariable(Object aObject) { + // for findbugs. + } public void testCompositeWithExternalDependencesProvided() { Component environment = new Environment(); @@ -553,7 +561,7 @@ public class ContainerTest extends TestCase { Scope external = new DefaultScope(new ProvidedInterface[0]); external.publishInterface(provided, 100); - Scope scope = container.start(external); + container.start(external); } public void testProvidedInterfaces() { @@ -631,7 +639,7 @@ public class ContainerTest extends TestCase { container.getRequiredInterfaces().get(1).setProvider(x); container.getRequiredInterfaces().get(2).setProvider(y); - Scope runtime = container.start(externalScope); + container.start(externalScope); assertEquals("y-value", app.getString()); }