Skip to content

Latest commit

 

History

History
90 lines (50 loc) · 1.86 KB

README.md

File metadata and controls

90 lines (50 loc) · 1.86 KB

SuperTest Cucumber API Testing Boilerplate 🚀🔬

Test and Publish Cucumber Report

A ready-to-use boilerplate for API testing using SuperTest and Cucumber with TypeScript.

Features

  • SuperTest for making HTTP requests and assertions
  • Cucumber for behavior-driven development (BDD) testing
  • TypeScript for type-safe code
  • Jest as the test runner
  • HTML report generation for test results

Project Structure

  • features/: Contains Cucumber feature files
  • features/support/: Contains step definitions and support files for Cucumber
  • specs/: Contains SuperTest specification files
  • report.js: Script to generate HTML reports

Configuration Files

  • jest.config.js: Jest configuration
  • cucumber.js: Cucumber configuration (if needed)
  • tsconfig.json: TypeScript configuration

Project Setup

🔧 Run the following command to install all the project dependencies:

npm install

Running Tests

Run All Tests

To run both SuperTest and Cucumber tests:

npm run test

Run SuperTest POC Tests

To run the SuperTest proof-of-concept tests:

npm run test:supertest

Run Cucumber E2E Tests

To execute the end-to-end tests using Cucumber:

npm run test:cucumber

Generate HTML Report

After running the Cucumber tests, generate an HTML report:

npm run generate:report

View Cucumber Report

You can view the latest Cucumber report on GitHub Pages:

View Cucumber Report

License

📝 Copyright © 2023 tooniez.
This project is MIT licensed.