add github workflow, fix test issues with server file #2
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
name: Test Api with Jest | |
on: | |
push: | |
branches: | |
- main | |
- production | |
- feature/** | |
pull_request: | |
branches: | |
- main | |
- production | |
jobs: | |
jest-testing: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build images | |
run: docker-compose build | |
- name: Run Test | |
run: docker-compose run --rm api sh -c "npm run test" | |