Skip to content

Latest commit

 

History

History
50 lines (35 loc) · 2.34 KB

File metadata and controls

50 lines (35 loc) · 2.34 KB

AutomationApiProject

Base example of an automation project to test APIs (BE)

Java + RestAssured + TestNG + mvn

Installation:

Desirable:

How to Run the tests:

  • Make sure to import this project as a mvn project instead of just opening the main folder
  • If you are using IntelliJ you may go to the Maven tab and update the project (Reload All Maven Projects - option), if you are using other IDE or no IDE at all go to the terminal/console, your project location and run:
    • mvn clean install

  • Go to your project folder > AutomationApiProject > src/test/testngRunners/ > SingleTest.xml file > right click & run
  • A new window will be opened and after a couple of ms you will get something like this:
===============================================
 AutomationApiSuite
 Total tests run: 1, Failures: 0, Skips: 0
===============================================

Process finished with exit code 0

If you get a failure could be a simple endpoint error,

if you get an error make sure all the mvn dependencies/packages are fully installed before running (it could take some time)

Available Suites:

There are at least three types of regression suites in this project:

  • Smoke test: /src/test/testngRunners/SingleTest.xml
  • Sanity test: /src/test/testngRunners/SanityApiRegression.xml
  • Full Regression: /src/test/testngRunners/FullApiRegression.xml

if you have already installed TestNG just need to right click > run 'Regression.xml' or to run all the tests use this file:

  • testng.xml

alt text

alt text

To dig in a bit more - Main Library documentation: