To run the tests, you will need to download or clone the project. You can use the following command to clone the repository:
git clone https://github.com/felipehsoliveira/sprite_test.gitIf the above command does not work, you can also download the project as a ZIP file by clicking the "Download ZIP" button, as shown below:
After downloading, navigate to the project folder. Once inside the project folder, access the project's root directory and install the necessary packages for running the tests using the following command:
npm installPlease note that for the project to work correctly, you must have the latest LTS version of Node.js installed on your device. If you don't have Node.js installed, please follow the steps outlined in the following link: Node.js Download and Installation.
To execute the test scenarios, use the following command in your terminal:
npx playwright testTo run the scenarios in UI mode, use the following command:
npx playwright test --uiThis project is configured with GitHub Actions workflows. If you want to simulate the GitHub Actions environment locally, you can use the "act" tool. Follow the instructions provided in the following project link to set up and use "act": nektos/act.
The choice and automation of test scenarios were made with the following considerations:
For E2E (End-to-End) scenarios, common situations were considered, such as:
- Delayed loading of elements or pages.
- Interaction with pop-ups or alerts.
- Elements with changing IDs or elements that change without notice.
For API scenarios, the user API was selected to represent common real-world situations. The main HTTP methods for CRUD operations (POST, GET, PUT, and DELETE) were used to validate the functionality.
