unit tests added for swagger.json endpoint #93
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node | |
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs | |
name: Node.js CI | |
on: | |
push: | |
branches: | |
- main | |
- issue-* | |
pull_request: | |
branches: | |
- main | |
- issue-* | |
jobs: | |
Build_App_and_Run_Tests: | |
runs-on: ubuntu-latest | |
permissions: | |
checks: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install the dependencies | |
run: npm ci | |
- name: Build the app and run the tests | |
run: npm start && npx wait-on http://localhost:3004 & | |
- name: Run the tests | |
run: npm test | |
- name: Kill all instances of node | |
run: killall node | |
- name: Test Report | |
uses: dorny/test-reporter@v1 | |
if: success() || failure() | |
with: | |
name: Test Report | |
path: ${{ github.workspace }}/reports/test-results.json | |
reporter: 'mocha-json' | |