The first thing you’ll need to do is add the following REST-Assured dependency to your project’s pom.xml file:
<dependency>
<groupId>com.jayway.restassured</groupId>
<artifactId>rest-assured</artifactId>
<version>2.1.0</version>
<scope>test</scope>
</dependency>
<groupId>com.jayway.restassured</groupId>
<artifactId>rest-assured</artifactId>
<version>2.1.0</version>
<scope>test</scope>
</dependency>
For me, this actually caused a classpath clash with groovy and jersey-spring due to incompatibility issues. Because of this, I had to add an exclusion and the followinggroovy-all dependency in order to get it to work in my environment:
<exclusions>
<exclusion>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy</artifactId>
</exclusion>
</exclusions>
<exclusion>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy</artifactId>
</exclusion>
</exclusions>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-all</artifactId>
<!– Needs to be the same version that REST Assured depends on –>
<version>2.2.0</version>
<artifactId>groovy-all</artifactId>
<!– Needs to be the same version that REST Assured depends on –>
<version>2.2.0</version>
</dependency>
So the final pom.xml entry looks like this:
Comments
Post a Comment