Add Unit Tests for Modal Component and NFT Submission Flow #216
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: Jest Tests | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 18 | |
- name: Install Frontend Dependencies | |
run: yarn install | |
- name: Run Emulator | |
run: yarn emulator & echo $! > emulator_pid.txt | |
- name: Seed Database | |
run: yarn seed | |
- name: Run Frontend Tests | |
run: yarn test --ci --watchAll=false --silent | |
- name: Stop Emulator | |
run: kill $(cat emulator_pid.txt) | |
if: always() | |
- name: Install Backend Dependencies | |
run: | | |
cd functions | |
yarn install | |
- name: Run Backend Tests | |
run: | | |
cd functions | |
yarn test --ci --watchAll=false |