Author: dkulp Date: Fri May 16 18:29:27 2014 New Revision: 1595288 URL: http://svn.apache.org/r1595288 Log: Squashed commit of the following: This closes #12
commit 301f71ebeea7b92498f40ee1cba88c6aa0f31ba7 Author: Christian Schneider <[email protected]> Date: Fri May 16 14:32:15 2014 +0200 ARIES-1190 Update aries proxy integration tests to pax exam 3 commit 51498bf576b6cbfbfdb569460d4c60a2379135fb Merge: 43ed39a 7b5d730 Author: Christian Schneider <[email protected]> Date: Fri May 16 12:20:43 2014 +0200 ARIES-1190 Update aries proxy integration tests to pax exam 3 commit 7b5d730d70231fab12ddcc18b76c6e0c43eb2fee Author: Christian Schneider <[email protected]> Date: Fri May 16 11:54:10 2014 +0200 ARIES-1190 Update aries proxy integration tests to pax exam 3 Modified: aries/trunk/proxy/proxy-itests/pom.xml aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractBasicProxyTest.java aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractProxyTest.java aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractWeavingProxyTest.java aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyBundlesTest.java aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyUberBundleTest.java aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyBundlesTest.java aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyUberBundleTest.java Modified: aries/trunk/proxy/proxy-itests/pom.xml URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/pom.xml?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/pom.xml (original) +++ aries/trunk/proxy/proxy-itests/pom.xml Fri May 16 18:29:27 2014 @@ -39,11 +39,17 @@ <developerConnection>scm:svn:https://svn.apache.org/repos/asf/aries/trunk/proxy/proxy-itests</developerConnection> <url>http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests</url> </scm> + + <properties> + <exam.version>3.4.0</exam.version> + <url.version>1.6.0</url.version> + </properties> <dependencies> <dependency> - <groupId>org.osgi</groupId> - <artifactId>org.osgi.core</artifactId> + <groupId>org.eclipse</groupId> + <artifactId>org.eclipse.osgi</artifactId> + <version>3.8.0.v20120529-1548</version> <scope>provided</scope> </dependency> <dependency> @@ -52,27 +58,10 @@ <scope>provided</scope> </dependency> <dependency> - <groupId>org.eclipse</groupId> - <artifactId>osgi</artifactId> - <scope>provided</scope> - </dependency> - <dependency> - <groupId>org.eclipse.tycho</groupId> - <artifactId>org.eclipse.osgi</artifactId> - <version>3.7.0.v20110613</version> - <scope>test</scope> - </dependency> - <dependency> - <groupId>org.apache.aries.proxy</groupId> - <artifactId>org.apache.aries.proxy</artifactId> - <scope>test</scope> - <version>1.0.2-SNAPSHOT</version> - </dependency> - <dependency> <groupId>org.apache.aries.proxy</groupId> <artifactId>org.apache.aries.proxy.api</artifactId> <scope>test</scope> - <version>1.0.0</version> + <version>1.0.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.apache.aries.proxy</groupId> @@ -89,77 +78,69 @@ <dependency> <groupId>org.apache.aries.testsupport</groupId> <artifactId>org.apache.aries.testsupport.unit</artifactId> - <version>1.0.0</version> + <version>2.0.0-SNAPSHOT</version> <scope>test</scope> </dependency> + + <!-- pax exam --> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.7</version> + </dependency> <dependency> <groupId>org.ops4j.pax.exam</groupId> <artifactId>pax-exam</artifactId> + <version>${exam.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.ops4j.pax.exam</groupId> - <artifactId>pax-exam-junit</artifactId> + <artifactId>pax-exam-container-forked</artifactId> + <version>${exam.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.ops4j.pax.exam</groupId> - <artifactId>pax-exam-container-default</artifactId> + <artifactId>pax-exam-junit4</artifactId> + <version>${exam.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.ops4j.pax.exam</groupId> - <artifactId>pax-exam-junit-extender-impl</artifactId> + <artifactId>pax-exam-link-mvn</artifactId> + <version>${exam.version}</version> <scope>test</scope> </dependency> <dependency> - <groupId>org.ops4j.pax.runner</groupId> - <artifactId>pax-runner-no-jcl</artifactId> - <version>1.8.5</version> + <groupId>org.ops4j.pax.url</groupId> + <artifactId>pax-url-aether</artifactId> + <version>${url.version}</version> + <scope>test</scope> </dependency> - <dependency> - <groupId>org.ops4j.pax.runner</groupId> - <artifactId>pax-runner-platform-equinox</artifactId> - <version>1.8.5</version> - </dependency> - - <dependency> - <groupId>junit</groupId> - <artifactId>junit</artifactId> + <groupId>ch.qos.logback</groupId> + <artifactId>logback-core</artifactId> + <version>0.9.29</version> <scope>test</scope> </dependency> <dependency> - <groupId>org.apache.felix</groupId> - <artifactId>org.apache.felix.configadmin</artifactId> - <version>1.2.4</version> - <exclusions> - <exclusion> - <groupId>org.apache.felix</groupId> - <artifactId>org.osgi.compendium</artifactId> - </exclusion> - <exclusion> - <groupId>org.apache.felix</groupId> - <artifactId>org.osgi.core</artifactId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>org.ops4j.pax.logging</groupId> - <artifactId>pax-logging-api</artifactId> - <version>1.7.2</version> + <groupId>ch.qos.logback</groupId> + <artifactId>logback-classic</artifactId> + <version>0.9.29</version> <scope>test</scope> </dependency> <dependency> - <groupId>org.ops4j.pax.logging</groupId> - <artifactId>pax-logging-service</artifactId> - <scope>test</scope> + <groupId>org.ops4j.pax.tinybundles</groupId> + <artifactId>tinybundles</artifactId> + <version>2.0.0</version> </dependency> <dependency> - <groupId>org.ops4j.pax.url</groupId> - <artifactId>pax-url-mvn</artifactId> + <groupId>junit</groupId> + <artifactId>junit</artifactId> <scope>test</scope> </dependency> + <dependency> <groupId>org.ow2.asm</groupId> <artifactId>asm-all</artifactId> @@ -172,7 +153,6 @@ <artifactId>javax.inject</artifactId> <version>1</version> <scope>test</scope> - </dependency> </dependencies> @@ -187,31 +167,21 @@ <artifactId>maven-surefire-plugin</artifactId> <configuration> <forkMode>pertest</forkMode> - <excludes> - <exclude>**/*$*</exclude> - <exclude>**/Abstract*.java</exclude> - </excludes> - <includes> - <include>**/Test*.java</include> - <include>**/*Test.java</include> - </includes> </configuration> </plugin> - <plugin> - <groupId>org.ops4j.pax.exam</groupId> - <artifactId>maven-paxexam-plugin</artifactId> - <executions> - <execution> - <id>generate-config</id> - <goals> - <goal>generate-depends-file</goal> - </goals> - <configuration> - <outputFile>${project.build.directory}/test-classes/META-INF/maven/dependencies.properties</outputFile> - </configuration> - </execution> - </executions> - </plugin> + <plugin> + <groupId>org.apache.servicemix.tooling</groupId> + <artifactId>depends-maven-plugin</artifactId> + <version>1.2</version> + <executions> + <execution> + <id>generate-depends-file</id> + <goals> + <goal>generate-depends-file</goal> + </goals> + </execution> + </executions> + </plugin> </plugins> </build> Modified: aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractBasicProxyTest.java URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractBasicProxyTest.java?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractBasicProxyTest.java (original) +++ aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractBasicProxyTest.java Fri May 16 18:29:27 2014 @@ -20,27 +20,17 @@ package org.apache.aries.proxy.itests; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertTrue; -import static org.ops4j.pax.exam.CoreOptions.equinox; -import static org.apache.aries.itest.ExtraOptions.*; import java.util.ArrayList; import java.util.Collection; import java.util.concurrent.Callable; import org.apache.aries.proxy.FinalModifierException; -import org.apache.aries.proxy.ProxyManager; import org.apache.aries.proxy.UnableToProxyException; import org.junit.Test; -import org.junit.runner.RunWith; -import org.ops4j.pax.exam.Option; -import org.ops4j.pax.exam.junit.JUnit4TestRunner; import org.osgi.framework.Bundle; -import org.osgi.framework.FrameworkUtil; -import static org.ops4j.pax.exam.CoreOptions.waitForFrameworkStartup; -import static org.ops4j.pax.exam.container.def.PaxRunnerOptions.vmOption; -@RunWith(JUnit4TestRunner.class) -public class AbstractBasicProxyTest extends AbstractProxyTest +public abstract class AbstractBasicProxyTest extends AbstractProxyTest { /** * This test does two things. First of all it checks that we throw a FinalModifierException if we @@ -50,8 +40,7 @@ public class AbstractBasicProxyTest exte @Test public void checkProxyFinalClass() throws UnableToProxyException { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); Callable<Object> c = new TestCallable(); Collection<Class<?>> classes = new ArrayList<Class<?>>(); classes.add(TestCallable.class); @@ -71,8 +60,7 @@ public class AbstractBasicProxyTest exte @Test public void checkProxyFinalMethods() throws UnableToProxyException { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); Callable<Object> c = new TestCallable(); Collection<Class<?>> classes = new ArrayList<Class<?>>(); Runnable r = new Runnable() { Modified: aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractProxyTest.java URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractProxyTest.java?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractProxyTest.java (original) +++ aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractProxyTest.java Fri May 16 18:29:27 2014 @@ -18,14 +18,16 @@ */ package org.apache.aries.proxy.itests; -import static org.apache.aries.itest.ExtraOptions.flatOptions; -import static org.apache.aries.itest.ExtraOptions.mavenBundle; -import static org.apache.aries.itest.ExtraOptions.paxLogging; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; -import static org.ops4j.pax.exam.CoreOptions.equinox; +import static org.ops4j.pax.exam.CoreOptions.composite; +import static org.ops4j.pax.exam.CoreOptions.junitBundles; +import static org.ops4j.pax.exam.CoreOptions.mavenBundle; +import static org.ops4j.pax.exam.CoreOptions.options; +import static org.ops4j.pax.exam.CoreOptions.systemProperty; +import static org.ops4j.pax.exam.CoreOptions.when; import java.lang.reflect.Method; import java.util.AbstractList; @@ -34,16 +36,25 @@ import java.util.Collection; import java.util.List; import java.util.concurrent.Callable; +import javax.inject.Inject; + import org.apache.aries.itest.AbstractIntegrationTest; import org.apache.aries.proxy.InvocationListener; import org.apache.aries.proxy.ProxyManager; import org.junit.Test; +import org.junit.runner.RunWith; +import org.ops4j.pax.exam.CoreOptions; import org.ops4j.pax.exam.Option; -import org.ops4j.pax.exam.container.def.PaxRunnerOptions; +import org.ops4j.pax.exam.junit.PaxExam; +import org.ops4j.pax.exam.spi.reactors.ExamReactorStrategy; +import org.ops4j.pax.exam.spi.reactors.PerClass; import org.osgi.framework.Bundle; -import org.osgi.framework.FrameworkUtil; -public class AbstractProxyTest extends AbstractIntegrationTest { +@RunWith(PaxExam.class) +@ExamReactorStrategy(PerClass.class) +public abstract class AbstractProxyTest extends AbstractIntegrationTest { + @Inject + ProxyManager mgr; public final static class TestCallable implements Callable<Object> { private Object list = new ArrayList<Object>(); @@ -141,11 +152,9 @@ public class AbstractProxyTest extends A } } - @SuppressWarnings("unchecked") @Test public void testEquals() throws Exception { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); TestCallable c = new TestCallable(); c.setReturn(new TestDelegate("One")); @@ -165,8 +174,7 @@ public class AbstractProxyTest extends A @Test public void testDelegation() throws Exception { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); TestCallable c = new TestCallable(); @@ -185,8 +193,7 @@ public class AbstractProxyTest extends A @Test public void testInterception() throws Exception { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); TestDelegate td = new TestDelegate("Hello"); @@ -226,9 +233,7 @@ public class AbstractProxyTest extends A @Test public void testDelegationAndInterception() throws Exception { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); - + Bundle b = bundleContext.getBundle(); TestCallable c = new TestCallable(); @@ -282,47 +287,38 @@ public class AbstractProxyTest extends A assertEquals(ex, listener.postInvokeExceptionalReturn); } - protected static Option[] generalOptions() { - return flatOptions(paxLogging("DEBUG"), - - // Bundles - mavenBundle("org.apache.aries", "org.apache.aries.util"), - mavenBundle("org.ow2.asm", "asm-all"), - // don't install the blueprint sample here as it will be installed onto the same framework as the blueprint core bundle - // mavenBundle("org.apache.aries.blueprint", "org.apache.aries.blueprint.sample").noStart(), - mavenBundle("org.osgi", "org.osgi.compendium") + protected Option generalOptions() { + String localRepo = System.getProperty("maven.repo.local"); + if (localRepo == null) { + localRepo = System.getProperty("org.ops4j.pax.url.mvn.localRepository"); + } + return composite( + junitBundles(), + systemProperty("org.ops4j.pax.logging.DefaultServiceLog.level").value("INFO"), + when(localRepo != null).useOptions(CoreOptions.vmOption("-Dorg.ops4j.pax.url.mvn.localRepository=" + localRepo)), + mavenBundle("org.apache.aries", "org.apache.aries.util").versionAsInProject(), + mavenBundle("org.ow2.asm", "asm-all").versionAsInProject(), + mavenBundle("org.apache.aries.testsupport", "org.apache.aries.testsupport.unit").versionAsInProject() /* vmOption ("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005"), waitForFrameworkStartup(),*/ ); - } - protected static Option[] proxyBundles() + protected Option[] proxyBundles() { - return new Option[] { - mavenBundle("org.apache.aries.proxy", "org.apache.aries.proxy.api"), - mavenBundle("org.apache.aries.proxy", "org.apache.aries.proxy.impl"), - }; + return options( + generalOptions(), + mavenBundle("org.apache.aries.proxy", "org.apache.aries.proxy.api").versionAsInProject(), + mavenBundle("org.apache.aries.proxy", "org.apache.aries.proxy.impl").versionAsInProject() + ); } - protected static Option[] proxyUberBundle() + protected Option[] proxyUberBundle() { - return new Option[] { - mavenBundle("org.apache.aries.proxy", "org.apache.aries.proxy"), - }; + return options( + generalOptions(), + mavenBundle("org.apache.aries.proxy", "org.apache.aries.proxy").version("1.0.2-SNAPSHOT") + ); } - protected static Option[] equinox35() - { - return new Option[] { - equinox().version("3.5.0") - }; - } - - protected static Option[] equinox37() - { - return new Option[] { - equinox().version("3.7.0") - }; - } } Modified: aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractWeavingProxyTest.java URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractWeavingProxyTest.java?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractWeavingProxyTest.java (original) +++ aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/AbstractWeavingProxyTest.java Fri May 16 18:29:27 2014 @@ -18,12 +18,8 @@ */ package org.apache.aries.proxy.itests; -import static org.apache.aries.itest.ExtraOptions.mavenBundle; -import static org.apache.aries.itest.ExtraOptions.paxLogging; -import static org.apache.aries.itest.ExtraOptions.testOptions; import static org.junit.Assert.assertSame; import static org.junit.Assert.fail; -import static org.ops4j.pax.exam.CoreOptions.equinox; import java.util.AbstractList; import java.util.ArrayList; @@ -31,21 +27,14 @@ import java.util.Collection; import java.util.concurrent.Callable; import org.apache.aries.proxy.FinalModifierException; -import org.apache.aries.proxy.ProxyManager; import org.apache.aries.proxy.weaving.WovenProxy; import org.apache.aries.proxy.weavinghook.ProxyWeavingController; import org.apache.aries.proxy.weavinghook.WeavingHelper; import org.junit.Test; -import org.junit.runner.RunWith; -import org.ops4j.pax.exam.Option; -import org.ops4j.pax.exam.container.def.PaxRunnerOptions; -import org.ops4j.pax.exam.junit.JUnit4TestRunner; import org.osgi.framework.Bundle; -import org.osgi.framework.FrameworkUtil; import org.osgi.framework.hooks.weaving.WovenClass; -@RunWith(JUnit4TestRunner.class) -public class AbstractWeavingProxyTest extends AbstractProxyTest +public abstract class AbstractWeavingProxyTest extends AbstractProxyTest { /** @@ -56,13 +45,13 @@ public class AbstractWeavingProxyTest ex @Test public void checkProxyFinalClass() throws Exception { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); TestCallable dispatcher = new TestCallable(); TestCallable template = new TestCallable(); Collection<Class<?>> classes = new ArrayList<Class<?>>(); classes.add(TestCallable.class); - Callable<Object> o = (Callable<Object>) mgr.createDelegatingProxy(b, classes, + @SuppressWarnings("unchecked") + Callable<Object> o = (Callable<Object>) mgr.createDelegatingProxy(b, classes, dispatcher, template); if(!!!(o instanceof WovenProxy)) fail("Proxy should be woven!"); @@ -80,8 +69,7 @@ public class AbstractWeavingProxyTest ex @Test public void checkProxyFinalMethods() throws Exception { - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); Callable<Object> c = new TestCallable(); Collection<Class<?>> classes = new ArrayList<Class<?>>(); Runnable r = new Runnable() { @@ -106,8 +94,7 @@ public class AbstractWeavingProxyTest ex } }, null); - ProxyManager mgr = context().getService(ProxyManager.class); - Bundle b = FrameworkUtil.getBundle(this.getClass()); + Bundle b = bundleContext.getBundle(); Callable<Object> c = new TestCallable(); Collection<Class<?>> classes = new ArrayList<Class<?>>(); // Don't use anonymous inner class in this test as IBM and Sun load it at a different time @@ -124,21 +111,18 @@ public class AbstractWeavingProxyTest ex @Override public String get(int location) { - return null; } @Override public int size() { - return 0; } public final String call() throws Exception { - return null; } } -} \ No newline at end of file +} Modified: aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyBundlesTest.java URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyBundlesTest.java?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyBundlesTest.java (original) +++ aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyBundlesTest.java Fri May 16 18:29:27 2014 @@ -18,31 +18,8 @@ */ package org.apache.aries.proxy.itests; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; -import static org.ops4j.pax.exam.CoreOptions.equinox; -import static org.apache.aries.itest.ExtraOptions.*; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.concurrent.Callable; - -import org.apache.aries.itest.AbstractIntegrationTest; -import org.apache.aries.proxy.FinalModifierException; -import org.apache.aries.proxy.ProxyManager; -import org.apache.aries.proxy.UnableToProxyException; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.ops4j.pax.exam.CoreOptions; +import org.ops4j.pax.exam.Configuration; import org.ops4j.pax.exam.Option; -import org.ops4j.pax.exam.container.def.PaxRunnerOptions; -import org.ops4j.pax.exam.container.def.options.CleanCachesOption; -import org.ops4j.pax.exam.junit.JUnit4TestRunner; -import org.osgi.framework.Bundle; -import org.osgi.framework.FrameworkUtil; -import static org.ops4j.pax.exam.CoreOptions.waitForFrameworkStartup; -import static org.ops4j.pax.exam.container.def.PaxRunnerOptions.vmOption; /** * This test runs the basic proxy tests for the proxy bundles (not the uber bundle). @@ -51,24 +28,11 @@ import static org.ops4j.pax.exam.contain * uber-bundle, which means we test nothing. * */ -@RunWith(JUnit4TestRunner.class) public class BasicProxyBundlesTest extends AbstractBasicProxyTest { - @org.ops4j.pax.exam.junit.Configuration - public static Option[] configuration35IndividualBundles() { - return testOptions( - generalOptions(), - proxyBundles(), - equinox35() - ); + @Configuration + public Option[] configuration() { + return proxyBundles(); } - @org.ops4j.pax.exam.junit.Configuration - public static Option[] configuration37IndividualBundles() { - return testOptions( - generalOptions(), - proxyBundles(), - equinox37() - ); - } } \ No newline at end of file Modified: aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyUberBundleTest.java URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyUberBundleTest.java?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyUberBundleTest.java (original) +++ aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/BasicProxyUberBundleTest.java Fri May 16 18:29:27 2014 @@ -18,31 +18,8 @@ */ package org.apache.aries.proxy.itests; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; -import static org.ops4j.pax.exam.CoreOptions.equinox; -import static org.apache.aries.itest.ExtraOptions.*; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.concurrent.Callable; - -import org.apache.aries.itest.AbstractIntegrationTest; -import org.apache.aries.proxy.FinalModifierException; -import org.apache.aries.proxy.ProxyManager; -import org.apache.aries.proxy.UnableToProxyException; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.ops4j.pax.exam.CoreOptions; +import org.ops4j.pax.exam.Configuration; import org.ops4j.pax.exam.Option; -import org.ops4j.pax.exam.container.def.PaxRunnerOptions; -import org.ops4j.pax.exam.container.def.options.CleanCachesOption; -import org.ops4j.pax.exam.junit.JUnit4TestRunner; -import org.osgi.framework.Bundle; -import org.osgi.framework.FrameworkUtil; -import static org.ops4j.pax.exam.CoreOptions.waitForFrameworkStartup; -import static org.ops4j.pax.exam.container.def.PaxRunnerOptions.vmOption; /** * This test runs the basic proxy tests for the proxy uber bundle. @@ -51,26 +28,12 @@ import static org.ops4j.pax.exam.contain * uber-bundle, which means we test nothing. * */ -@RunWith(JUnit4TestRunner.class) public class BasicProxyUberBundleTest extends AbstractBasicProxyTest { - @org.ops4j.pax.exam.junit.Configuration - public static Option[] configuration35UberBundle() { - return testOptions( - generalOptions(), - proxyUberBundle(), - equinox35() - ); - } - - @org.ops4j.pax.exam.junit.Configuration - public static Option[] configuration37UberBundle() { - return testOptions( - generalOptions(), - proxyUberBundle(), - equinox37() - ); + @Configuration + public Option[] configuration() { + return proxyUberBundle(); } } \ No newline at end of file Modified: aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyBundlesTest.java URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyBundlesTest.java?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyBundlesTest.java (original) +++ aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyBundlesTest.java Fri May 16 18:29:27 2014 @@ -18,31 +18,8 @@ */ package org.apache.aries.proxy.itests; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; -import static org.ops4j.pax.exam.CoreOptions.equinox; -import static org.apache.aries.itest.ExtraOptions.*; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.concurrent.Callable; - -import org.apache.aries.itest.AbstractIntegrationTest; -import org.apache.aries.proxy.FinalModifierException; -import org.apache.aries.proxy.ProxyManager; -import org.apache.aries.proxy.UnableToProxyException; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.ops4j.pax.exam.CoreOptions; +import org.ops4j.pax.exam.Configuration; import org.ops4j.pax.exam.Option; -import org.ops4j.pax.exam.container.def.PaxRunnerOptions; -import org.ops4j.pax.exam.container.def.options.CleanCachesOption; -import org.ops4j.pax.exam.junit.JUnit4TestRunner; -import org.osgi.framework.Bundle; -import org.osgi.framework.FrameworkUtil; -import static org.ops4j.pax.exam.CoreOptions.waitForFrameworkStartup; -import static org.ops4j.pax.exam.container.def.PaxRunnerOptions.vmOption; /** * This test runs the weaving proxy tests for the proxy bundles (not the uber bundle). @@ -51,15 +28,10 @@ import static org.ops4j.pax.exam.contain * uber-bundle, which means we test nothing. * */ -@RunWith(JUnit4TestRunner.class) public class WeavingProxyBundlesTest extends AbstractWeavingProxyTest { - @org.ops4j.pax.exam.junit.Configuration - public static Option[] configuration37IndividualBundles() { - return testOptions( - generalOptions(), - proxyBundles(), - equinox37() - ); + @Configuration + public Option[] configuration() { + return proxyBundles(); } } \ No newline at end of file Modified: aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyUberBundleTest.java URL: http://svn.apache.org/viewvc/aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyUberBundleTest.java?rev=1595288&r1=1595287&r2=1595288&view=diff ============================================================================== --- aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyUberBundleTest.java (original) +++ aries/trunk/proxy/proxy-itests/src/test/java/org/apache/aries/proxy/itests/WeavingProxyUberBundleTest.java Fri May 16 18:29:27 2014 @@ -18,31 +18,8 @@ */ package org.apache.aries.proxy.itests; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; -import static org.ops4j.pax.exam.CoreOptions.equinox; -import static org.apache.aries.itest.ExtraOptions.*; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.concurrent.Callable; - -import org.apache.aries.itest.AbstractIntegrationTest; -import org.apache.aries.proxy.FinalModifierException; -import org.apache.aries.proxy.ProxyManager; -import org.apache.aries.proxy.UnableToProxyException; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.ops4j.pax.exam.CoreOptions; +import org.ops4j.pax.exam.Configuration; import org.ops4j.pax.exam.Option; -import org.ops4j.pax.exam.container.def.PaxRunnerOptions; -import org.ops4j.pax.exam.container.def.options.CleanCachesOption; -import org.ops4j.pax.exam.junit.JUnit4TestRunner; -import org.osgi.framework.Bundle; -import org.osgi.framework.FrameworkUtil; -import static org.ops4j.pax.exam.CoreOptions.waitForFrameworkStartup; -import static org.ops4j.pax.exam.container.def.PaxRunnerOptions.vmOption; /** * This test runs the weaving proxy tests for the proxy uber bundle. @@ -51,16 +28,11 @@ import static org.ops4j.pax.exam.contain * uber-bundle, which means we test nothing. * */ -@RunWith(JUnit4TestRunner.class) public class WeavingProxyUberBundleTest extends AbstractWeavingProxyTest { - @org.ops4j.pax.exam.junit.Configuration - public static Option[] configuration37UberBundle() { - return testOptions( - generalOptions(), - proxyUberBundle(), - equinox37() - ); + @Configuration + public Option[] configuration() { + return proxyUberBundle(); } } \ No newline at end of file
