要添加哪些 Jersey 依赖项以避免 NoClassDefFoundError for jersey.repackaged.com.google.common.collect.Maps
我正在尝试运行一个扩展的测试,但在运行它时,我得到了一个:JerseyTest
java.lang.NoClassDefFoundError: jersey/repackaged/com/google/common/collect/Maps
你知道我错过了什么依赖关系吗?我已经在我的和球衣中包含了以下球衣文物.version是2.5.1:pom.xml
<dependency>
<groupId>org.glassfish.jersey.containers</groupId>
<artifactId>jersey-container-servlet</artifactId>
<version>${jersey.version}</version>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.core</groupId>
<artifactId>jersey-client</artifactId>
<version>${jersey.version}</version>
</dependency>
<dependency>
<groupId>com.sun.jersey.jersey-test-framework</groupId>
<artifactId>jersey-test-framework-core</artifactId>
<version>1.18</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.test-framework.providers</groupId>
<artifactId>jersey-test-framework-provider-grizzly2</artifactId>
<version>2.6</version>
<scope>test</scope>
</dependency>