feat: Add e2e testing #19
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: E2E Tests | |
on: | |
pull_request: | |
types: [opened, synchronize, reopened] | |
jobs: | |
test: | |
name: Test | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [18.x] | |
steps: | |
- name: Checkout code | |
uses: actions/[email protected] | |
- name: Install Node.js ${{ matrix.node-version }} | |
uses: actions/[email protected] | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Run Docker | |
run: docker compose up --build -d | |
- name: Wait | |
run: sleep 80s | |
- name: Install dependencies | |
run: yarn install | |
- name: Run tests | |
run: yarn run test:e2e | |
- name: Clean up Docker containers | |
if: always() | |
run: docker compose down |