Skip to content

Commit

Permalink
Add migrations check in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
aberonni committed Sep 2, 2024
1 parent 59087ae commit 31fec81
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ jobs:
run: npx playwright install --with-deps
- name: Start dev server
run: npm run dev > /dev/null 2>&1 &
- name: Make sure there are no pending migrations
run: npx prisma migrate diff --from-migrations ./prisma/migrations --to-schema-datamodel ./prisma/schema --exit-code --shadow-database-url=${{ env.DATABASE_URL }}
- name: Wait for dev server to be ready
run: timeout 60s sh -c 'until curl http://localhost:3000 -I; do echo "Waiting for dev server to be running..."; sleep 2; done'
- name: Run Playwright tests
Expand Down
3 changes: 3 additions & 0 deletions prisma/migrations/migration_lock.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Please do not edit this file manually
# It should be added in your version-control system (i.e. Git)
provider = "postgresql"

0 comments on commit 31fec81

Please sign in to comment.