In this blog
we would be learning How to Configure Rest Assured in our eclipse project.
1) JAVA ร Any version of Java would work but in
this blog I am using JAVA 8.
2) Maven ร Maven plugin should be installed in
code editor and also in our local machine to run the test cases from the command prompt.
3) Code Editor ร any code editor like the eclipse, Intellij
IDEA or Visual Studio would work. I am using Eclipse for this.
4) Testing Framework ร To validate our test we need a testing frameworks like Junit or TestNG. I will be using TestNG through out this blog.
5) Rest Assured Jars or Maven Dependency.
To download Rest assured JARS please click on this link. Under
Current Direct download install as per our requirement.
Or to download respective maven dependency please click on
this link.
1) Now let’s start by creating one simple
maven project in eclipse. The project structure should be like below:
2) Add the rest assured maven dependency
in our pom.xml file. In this blog I would be using below maven dependencies for
different purposes.
In the next blog, we would be learning how to write our first test to automate API using Rest Assured.
Hi Sir,
ReplyNeed some help related to configuration for Rest Assured in Eclipse. Getting red exclamation mark over my project name in Eclipse when I add rest assure dependency. Below are the configuration setting:
Eclipse: Neon.1 Release RC3 (4.6.1RC3)
Java: 1.8.0_111
Maven: Maven Integration for Eclipse (Luna) 1.5.0
Adding below Rest Assured dependency:
1) rest-assured (3.1.0)
2) Json path (3.1.0)
3) Json Schema Validator (3.1.0)
4) XML path (3.0.7)
5) Hamcrest (2.0.0.0
6) TestNG (6.14.2)