This is a sample REST API Test Automation Framework using Java, REST Assured, Cucumber BDD, and Maven. The project demonstrates CRUD operations on product APIs.
src/
β
βββ main/java/com/example/productapi
β βββ apirouting/ # Base REST call routing setup
β βββ config/ # API and Global config files
β βββ product/ # Product configuration classes
β βββ modules/products/ # Business logic modules for product operations
β βββ pojos/productPayloads/ # Request and response payload POJOs
β βββ restAssuredApiCalls/ # Core REST Assured call utilities
β βββ utils/sontopojo/ # JSON utility helpers
β
βββ test/java/product/cucumber
β βββ runners/ # Cucumber test runners
β βββ stepdefinitions/ # Glue code for step definitions
β
βββ resources/features/products/ # Feature files (Add, Get, Update, Delete)
β
βββ pom.xml # Maven configuration
- Add Product
- Get Products
- Update Product
- Delete Product
Each feature is covered through:
- Cucumber feature file (
.feature
) - Step Definitions in Java
- Modular and reusable code structure
- Java 11+
- REST Assured
- Cucumber BDD
- Maven
- JUnit
- Gherkin (for feature files)
- Java JDK 11 or higher
- Maven installed
- IDE (e.g., IntelliJ, Eclipse)
To execute the tests via Maven:
mvn clean test