Skip to content

Commit

Permalink
Testing run unit tests on each push
Browse files Browse the repository at this point in the history
  • Loading branch information
MatheusSanchez committed Jan 25, 2024
1 parent 08c465f commit 89a3a86
Show file tree
Hide file tree
Showing 2 changed files with 58 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/run-e2e-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Run E2E Tests

on: [push]

jobs:
run-unit-tests:
name: Run E2E Tests
runs-on: ubuntu-latest

services:
postgres:
image: bitnami/postgresql
ports:
- 8080:5432
env:
POSTGRESQL_USERNAME: docker
POSTGRESQL_PASSWORD: docker
POSTGRESQL_DATABASE: orange-db

steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
cache: 'pnpm'

- run: pnpm install

- run: pnpm run pretest:e2e
- run: pnpm run test:e2e

env:
DATABASE_URL: "postgresql://docker:docker@localhost:8080/orange-db?schema=public"
22 changes: 22 additions & 0 deletions .github/workflows/run-unit-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Run Unit Tests

on: [push]

jobs:
run-unit-tests:
name: Run Unit Tests
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
cache: 'pnpm'

- run: pnpm install

- run: pnpm run test

0 comments on commit 89a3a86

Please sign in to comment.