Giter Club home page Giter Club logo

api-testing's Introduction

APIs Testing

This repository shows how to use Http files and Rest Client to automate the end-to-end (e2e) testing of APIs.

Prerequisites

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.

Documentation

Running

Before running the application, make sure you have:

  • Installed the Pre-requisites mentioned above.
  • Created the environment file .env under root folder based on the template file .env.template.
  • the environment file http-client.env.json under e2e-test folder is up to date.

To build the service source code and run unit-tests, use:

  • make build or mvn clean install

To run the service in development mode, use:

  • make run or mvn 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 dashboard

Run e2e test

To run e2e test, you need to:

  • Install [httpyac] CLI tool by running make e2e-init or npm install -g httpyac
  • Run the API service in dev mode by running make run or mvn spring-boot:run
  • Run the e2e test by running make e2e-local or httpyac testing/e2e-test/*.http --all -e local -o response

api-testing's People

Contributors

aymalla avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.