Restore duplicate check 26/77326/1
authorStephen Kitt <skitt@redhat.com>
Mon, 29 Oct 2018 16:03:24 +0000 (17:03 +0100)
committerStephen Kitt <skitt@redhat.com>
Mon, 29 Oct 2018 16:05:26 +0000 (17:05 +0100)
With the recent odlparent and yangtools bumps in Fluorine, the
handling of jaxb-api and activation changed; for features, this is
dealt with by excluding the relevant artifacts from generated
features, but other tests end up with duplicates since the artifacts
include classes which are also present in the JVM’s rt.jar.

This patch excludes jaxb-api and activation, and restores the
duplicate check.

JIRA: INFRAUTILS-59
Change-Id: Ifa8f0fd86c8b65655cc50261f198d3deb2411499
Signed-off-by: Stephen Kitt <skitt@redhat.com>
integration/test-standalone/pom.xml
integration/test-standalone/src/test/java/org/opendaylight/neutron/e2etest/NeutronE2ETest.java

index c59544f7895b00fa5a388b6b8f6572744dbbdab6..113817efe06d81059c5600d4543e3951a8c24784 100644 (file)
       <artifactId>sal-binding-broker-impl</artifactId>
       <version>1.8.1-SNAPSHOT</version>
       <scope>test</scope>
+      <exclusions>
+        <exclusion>
+          <groupId>javax.xml.bind</groupId>
+          <artifactId>jaxb-api</artifactId>
+        </exclusion>
+        <exclusion>
+          <groupId>javax.activation</groupId>
+          <artifactId>activation</artifactId>
+        </exclusion>
+      </exclusions>
     </dependency>
     <dependency>
       <groupId>org.opendaylight.controller</groupId>
index cc30477ae9f405527d787ceb400900b6d98031bf..c07effcb2f45a5e4c9c8b80fdd114540f718ab1d 100644 (file)
@@ -9,11 +9,13 @@ package org.opendaylight.neutron.e2etest;
 
 import java.io.IOException;
 import javax.inject.Inject;
+import org.junit.ClassRule;
 import org.junit.Rule;
 import org.junit.Test;
 import org.opendaylight.aaa.web.WebServer;
 import org.opendaylight.infrautils.inject.guice.testutils.AnnotationsModule;
 import org.opendaylight.infrautils.inject.guice.testutils.GuiceRule;
+import org.opendaylight.infrautils.testutils.ClasspathHellDuplicatesCheckRule;
 
 /**
  * Neutron "end to end" (component) test.
@@ -24,8 +26,7 @@ import org.opendaylight.infrautils.inject.guice.testutils.GuiceRule;
  */
 public class NeutronE2ETest {
 
-    // TODO INFRAUTILS-59 reactivate the ClasspathHellDuplicatesCheckRule here:
-    // public static @ClassRule ClasspathHellDuplicatesCheckRule jHades = new ClasspathHellDuplicatesCheckRule();
+    public static @ClassRule ClasspathHellDuplicatesCheckRule jHades = new ClasspathHellDuplicatesCheckRule();
 
     public @Rule GuiceRule guice = new GuiceRule(NeutronTestWiring.class, AnnotationsModule.class);