Skip to content

Commit

Permalink
Support rails 7
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandermeindl committed Jan 31, 2024
1 parent 478c998 commit 48dc30a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:

jobs:
test:
name: ${{ matrix.redmine }} ${{ matrix.db }} ruby-${{ matrix.ruby }}
name: ruby-${{ matrix.ruby }}
runs-on: ubuntu-latest

strategy:
Expand Down
2 changes: 1 addition & 1 deletion test/redmine/models/issue.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
require_relative 'project'
require_relative 'user'

class Issue < ActiveRecord::Base
class Issue < Rails.version < '7.1' ? ActiveRecord::Base : ApplicationRecord
belongs_to :project
belongs_to :user
belongs_to :author, class_name: 'User'
Expand Down
2 changes: 1 addition & 1 deletion test/redmine/models/project.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# frozen_string_literal: true

class Project < ActiveRecord::Base
class Project < Rails.version < '7.1' ? ActiveRecord::Base : ApplicationRecord
STATUS_ACTIVE = 1
has_many :issues, dependent: :destroy

Expand Down
2 changes: 1 addition & 1 deletion test/redmine/models/user.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# frozen_string_literal: true

class User < ActiveRecord::Base
class User < Rails.version < '7.1' ? ActiveRecord::Base : ApplicationRecord
has_many :issues

def self.current
Expand Down

0 comments on commit 48dc30a

Please sign in to comment.