Update: An issue was created to fix the pipeline flakiness :: #23
This repository contains practice API tests using Cypress, designed to test a pet store's API. The following API was used for practice: PetStore
Thinking on an E2E approach, the following scenarios were created with test cases and automated, there are a lot more possible scenarios to cover this API, but these were selected as an example to represent business interactions.
Scenarios | Issues | Test Cases |
---|---|---|
1- As a Manager I want to update the Pet Inventory with addition/update/removal of pets | Scenario - 1 | 4 |
2- As a Manager I cannot update a removed pet from the inventory (negative/error scenario) | Scenario - 2 | 1 |
3- As a Customer I want to choose a pet and buy it | Scenario - 3 | 2 |
4- As a Customer I want to manage and cancel my order | Scenario - 4 | 2 |
Github Project and the following issues were created to help streamline manual testing, as well as serve as a guide for test automation. Some of the preconditions described there, were only necessary for manual tests. Automated tests are capable fulfilling those preconditions in a self contained way.
Prerequisites
- Node.js
- Cypress
- GitBash (for windows users)
To run this project locally, you will need to clone the repository:
git clone https://github.com/jacqueqa/petStore.git
After clonning, open the project on VSCode then run the command:
npm install
To run the tests:
npx cypress run
You can check the daily pipeline results here: