- Project Overview
- Features
- Installation
- Configuration
- Usage
- Folder Structure
- Dependencies
- Reporting and Logs
- HTTP Status Codes
- Contributors
- License
- Contact
The Rest Assured API Test Lab is an API testing framework designed to automate the testing of backend services.
This project uses Rest Assured, TestNG, Hamcrest, and JavaFaker to ensure the accuracy and stability of API endpoints.
It is tailored for educational purposes and testing REST APIs for the Mersys Campus application.
- Automated API Testing – Supports CRUD operations with
GET
,POST
,PUT
, andDELETE
requests. - Dynamic Data – Uses JavaFaker to generate random data for testing.
- Reusable Components – Modular design for reusable request and response specifications.
- Logging and Reporting – Logs API requests and responses, with TestNG-generated HTML reports.
- Parallel Execution – Supports concurrent test execution for efficiency.
git clone https://github.com/cihat-kose/restassured-api-test-lab.git
- File > New > Project from Version Control
- Enter Repository URL:
https://github.com/cihat-kose/restassured-api-test-lab.git
- Maven auto-import will download dependencies automatically.
⚙️ If dependencies are not downloaded automatically:
mvn clean install
- TestNG
- Maven Helper
- REST Client
- Lombok (Optional if used in the project)
Run the following command to verify that tests execute correctly:
mvn test
- Base URI:
https://test.mersys.io
- Authentication:
{
"username": "turkeyts",
"password": "TechnoStudy123",
"rememberMe": true
}
- Endpoints:
- Create Attestation:
/school-service/api/attestation
- Update Attestation:
/school-service/api/attestation
- Delete Attestation:
/school-service/api/attestation/{id}
- Create Attestation:
To run all tests:
mvn clean test
Or, right-click on any test file in IntelliJ and select:
Run 'ClassName'
restassured-api-test-lab/
│
├── src/
│ └── test/
│ ├── java/
│ │ ├── campus/ # Campus API tests
│ │ └── reqresIn/ # Reqres API tests
│ └── resources/
│ └── testng.xml # TestNG configuration
├── target/ # Build output
├── images/ # Project images
│ └── HTTP_Status_Codes.png
├── LICENSE # License file (MIT License)
├── pom.xml # Maven dependencies
└── README.md # Project documentation
Managed in pom.xml
. Key dependencies include:
- Rest Assured – API testing
- TestNG – Test execution
- Hamcrest – Enhanced assertions
- Jackson – JSON parsing
- JavaFaker – Dynamic data generation
- HTML Reports – Available at
target/surefire-reports/
. - Logs – API requests and responses are logged for debugging.
cat target/surefire-reports/emailable-report.html
This project commonly encounters a variety of HTTP status codes in responses.
Below is a summary of some frequently used status codes and their meanings:
- cihat-kose – Software Tester
To contribute:
- Fork the repository.
- Create a new branch (
git checkout -b feature-branch
). - Commit your changes (
git commit -m 'Add new feature'
). - Push to the branch (
git push origin feature-branch
). - Create a Pull Request.
This project is licensed under the MIT License.
See the LICENSE file for details.
For any questions or contributions, please open an issue in this repository.