This repository shows how to use Http files and Rest Client to automate the end-to-end (e2e) testing of APIs.
Note: If you are using dev-container, you don't need to install any of the above. Just open the project in VSCode and it will install all the required tools for you.
Before running the application, make sure you have:
- Installed the Pre-requisites mentioned above.
- Created the environment file
.envunder root folder based on the template file .env.template. - the environment file http-client.env.json under
e2e-testfolder is up to date.
To build the service source code and run unit-tests, use:
make buildormvn clean install
To run the service in development mode, use:
make runormvn spring-boot:run
The following is a list of make commands should be run from root folder.
help 💬 This help message :)
build 🔨 build the application and run unit-test
run 🏃 Run the application
e2e-init 🔨 Initialize e2e test environment by installing httpyac CLI
e2e-local 💻 Run e2e-test on your local environment
e2e-dev 💻 Run e2e-test on Backbase-msft-dev environment
load-test 🪓 Load Test
load-test-dashboard 🌄 Load Test with visualizing the results in xk6 dashboardTo run e2e test, you need to:
- Install [httpyac] CLI tool by running
make e2e-initornpm install -g httpyac - Run the API service in dev mode by running
make runormvn spring-boot:run - Run the e2e test by running
make e2e-localorhttpyac testing/e2e-test/*.http --all -e local -o response