Add support activerecord 8.1#589
Conversation
…abetically in all test SQL and create_table definitions
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for ActiveRecord 8.1 by updating the dependency constraint and adapting test fixtures to accommodate ActiveRecord 8.1's alphabetical column ordering in schema dumps. The changes ensure compatibility with Rails 8.1 (released) while maintaining backward compatibility with existing versions.
Key changes:
- Updated
activerecordgem dependency to support versions>= 6.1, < 8.2 - Reordered columns in test fixtures to match ActiveRecord 8.1's alphabetical schema dumping
- Reordered index definitions in SQL fixtures to maintain alphabetical consistency
Reviewed Changes
Copilot reviewed 119 out of 119 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| ridgepole.gemspec | Updated activerecord dependency upper bound from 8.1 to 8.2 |
| spec/postgresql/ridgepole_test_tables.sql | Reordered columns and indexes alphabetically in SQL table definitions |
| spec/postgresql/migrate/*.rb | Reordered columns alphabetically in create_table blocks across multiple migration specs |
| spec/mysql/ridgepole_test_tables.sql | Reordered columns and indexes alphabetically in SQL table definitions |
| spec/mysql/migrate/*.rb | Reordered columns alphabetically in create_table blocks across multiple migration specs |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
There was a problem hiding this comment.
Pull Request Overview
Copilot reviewed 118 out of 118 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…ls/rails#53281 by sorting columns alphabetically in all test SQL and create_table definitions
There was a problem hiding this comment.
Pull Request Overview
Copilot reviewed 119 out of 119 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
@winebarrel |
|
3.1.0 has been released |
Thank you for always maintaining ridgepole. 🚀
To support Active Record (activerecord gem) 8.1, I added it to the CI test matrix and also fixed issue #524 and others (see below).
Notes
ActiveRecord Version Description
About contents of the commit 271f44a
Since this update affects ActiveRecord 8.1 users due to issue #524, I fixed the content of #524 together.
About contents of the commit b4bc938
Due to the changes introduced in rails/rails#53281, ActiveRecord::SchemaDumper now dumps schema definitions in alphabetical order.
As a result, tests in Rails 8.1 started failing when the columns in create_table statements or SQL definitions were not listed alphabetically.To address this, we updated the column order in our test create_table blocks and SQL statements to follow alphabetical order.
In this commit, only the column order within the tests was changed to be alphabetical; the test logic itself remains unchanged.