Skip to content

Migration test#1267

Open
fbacall wants to merge 3 commits intomasterfrom
migration-test
Open

Migration test#1267
fbacall wants to merge 3 commits intomasterfrom
migration-test

Conversation

@fbacall
Copy link
Member

@fbacall fbacall commented Mar 25, 2026

Summary of changes

  • Adds a GitHub action to test database migrations, which runs if any files are changed under db/migrate/.

Motivation and context

I merged a PR with a broken migration

Checklist

  • I have read and followed the CONTRIBUTING guide.
  • I confirm that I have the authority necessary to make this contribution on behalf of its copyright owner and agree to license it to the TeSS codebase under the BSD license.

@fbacall fbacall requested a review from Copilot March 25, 2026 14:01
@fbacall fbacall marked this pull request as ready for review March 25, 2026 14:03
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a dedicated GitHub Actions workflow to validate that new database migrations can run cleanly by starting from the previously committed schema/migrations, helping prevent broken migrations from being merged.

Changes:

  • Add .github/workflows/migration-test.yml workflow that triggers on changes under db/migrate/**.
  • In the workflow, load the “previous” db/schema.rb (and migrations) into the test DB, then restore current migrations and run rails db:migrate.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants