From 34f178303199ddaec2e71dd268858bcf3ba07c2a Mon Sep 17 00:00:00 2001 From: Jacob Cody Wimer Date: Wed, 8 Oct 2025 11:35:44 -0400 Subject: [PATCH] Upgraded to rails 8.0.2 --- Gemfile | 2 +- Gemfile.lock | 127 +++++++++++----------- bin/dev | 4 +- config/application.rb | 2 + config/initializers/assets.rb | 7 ++ test/fixtures/tournament_job_statuses.yml | 22 ---- test/models/mat_test.rb | 2 +- test/models/school_test.rb | 2 +- test/models/weight_test.rb | 2 +- test/models/wrestler_test.rb | 2 +- 10 files changed, 80 insertions(+), 92 deletions(-) create mode 100644 config/initializers/assets.rb diff --git a/Gemfile b/Gemfile index 8087b6f..edcba47 100644 --- a/Gemfile +++ b/Gemfile @@ -2,7 +2,7 @@ source 'https://rubygems.org' ruby '3.2.0' # Bundle edge Rails instead: gem 'rails', github: 'rails/rails' -gem 'rails', '8.0.2' +gem 'rails', '8.0.3' # Added in rails 7.1 gem 'rails-html-sanitizer' diff --git a/Gemfile.lock b/Gemfile.lock index 12b0aa7..061b75f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,29 +1,29 @@ GEM remote: https://rubygems.org/ specs: - actioncable (8.0.2) - actionpack (= 8.0.2) - activesupport (= 8.0.2) + actioncable (8.0.3) + actionpack (= 8.0.3) + activesupport (= 8.0.3) nio4r (~> 2.0) websocket-driver (>= 0.6.1) zeitwerk (~> 2.6) - actionmailbox (8.0.2) - actionpack (= 8.0.2) - activejob (= 8.0.2) - activerecord (= 8.0.2) - activestorage (= 8.0.2) - activesupport (= 8.0.2) + actionmailbox (8.0.3) + actionpack (= 8.0.3) + activejob (= 8.0.3) + activerecord (= 8.0.3) + activestorage (= 8.0.3) + activesupport (= 8.0.3) mail (>= 2.8.0) - actionmailer (8.0.2) - actionpack (= 8.0.2) - actionview (= 8.0.2) - activejob (= 8.0.2) - activesupport (= 8.0.2) + actionmailer (8.0.3) + actionpack (= 8.0.3) + actionview (= 8.0.3) + activejob (= 8.0.3) + activesupport (= 8.0.3) mail (>= 2.8.0) rails-dom-testing (~> 2.2) - actionpack (8.0.2) - actionview (= 8.0.2) - activesupport (= 8.0.2) + actionpack (8.0.3) + actionview (= 8.0.3) + activesupport (= 8.0.3) nokogiri (>= 1.8.5) rack (>= 2.2.4) rack-session (>= 1.0.1) @@ -31,35 +31,35 @@ GEM rails-dom-testing (~> 2.2) rails-html-sanitizer (~> 1.6) useragent (~> 0.16) - actiontext (8.0.2) - actionpack (= 8.0.2) - activerecord (= 8.0.2) - activestorage (= 8.0.2) - activesupport (= 8.0.2) + actiontext (8.0.3) + actionpack (= 8.0.3) + activerecord (= 8.0.3) + activestorage (= 8.0.3) + activesupport (= 8.0.3) globalid (>= 0.6.0) nokogiri (>= 1.8.5) - actionview (8.0.2) - activesupport (= 8.0.2) + actionview (8.0.3) + activesupport (= 8.0.3) builder (~> 3.1) erubi (~> 1.11) rails-dom-testing (~> 2.2) rails-html-sanitizer (~> 1.6) - activejob (8.0.2) - activesupport (= 8.0.2) + activejob (8.0.3) + activesupport (= 8.0.3) globalid (>= 0.3.6) - activemodel (8.0.2) - activesupport (= 8.0.2) - activerecord (8.0.2) - activemodel (= 8.0.2) - activesupport (= 8.0.2) + activemodel (8.0.3) + activesupport (= 8.0.3) + activerecord (8.0.3) + activemodel (= 8.0.3) + activesupport (= 8.0.3) timeout (>= 0.4.0) - activestorage (8.0.2) - actionpack (= 8.0.2) - activejob (= 8.0.2) - activerecord (= 8.0.2) - activesupport (= 8.0.2) + activestorage (8.0.3) + actionpack (= 8.0.3) + activejob (= 8.0.3) + activerecord (= 8.0.3) + activesupport (= 8.0.3) marcel (~> 1.0) - activesupport (8.0.2) + activesupport (8.0.3) base64 benchmark (>= 0.3) bigdecimal @@ -76,7 +76,7 @@ GEM base64 (0.3.0) bcrypt (3.1.20) benchmark (0.4.1) - bigdecimal (3.2.3) + bigdecimal (3.3.0) bootsnap (1.18.6) msgpack (~> 1.2) brakeman (7.1.0) @@ -95,7 +95,7 @@ GEM daemons (1.4.1) date (3.4.1) drb (2.2.3) - erb (5.0.2) + erb (5.0.3) erubi (1.13.1) et-orbi (1.4.0) tzinfo @@ -126,7 +126,7 @@ GEM rails-dom-testing (>= 1, < 3) railties (>= 4.2.0) thor (>= 0.14, < 2.0) - json (2.15.0) + json (2.15.1) language_server-protocol (3.17.0.5) lint_roller (1.1.0) logger (1.7.0) @@ -146,7 +146,7 @@ GEM msgpack (1.8.0) mysql2 (0.5.7) bigdecimal - net-imap (0.5.11) + net-imap (0.5.12) date net-protocol net-pop (0.1.2) @@ -176,7 +176,7 @@ GEM parser (3.3.9.0) ast (~> 2.4.1) racc - pp (0.6.2) + pp (0.6.3) prettyprint prettyprint (0.2.0) prism (1.5.1) @@ -191,7 +191,7 @@ GEM nio4r (~> 2.0) raabro (1.4.0) racc (1.8.1) - rack (3.2.1) + rack (3.2.2) rack-session (2.1.1) base64 (>= 0.1.0) rack (>= 3.0.0) @@ -199,20 +199,20 @@ GEM rack (>= 1.3) rackup (2.2.1) rack (>= 3) - rails (8.0.2) - actioncable (= 8.0.2) - actionmailbox (= 8.0.2) - actionmailer (= 8.0.2) - actionpack (= 8.0.2) - actiontext (= 8.0.2) - actionview (= 8.0.2) - activejob (= 8.0.2) - activemodel (= 8.0.2) - activerecord (= 8.0.2) - activestorage (= 8.0.2) - activesupport (= 8.0.2) + rails (8.0.3) + actioncable (= 8.0.3) + actionmailbox (= 8.0.3) + actionmailer (= 8.0.3) + actionpack (= 8.0.3) + actiontext (= 8.0.3) + actionview (= 8.0.3) + activejob (= 8.0.3) + activemodel (= 8.0.3) + activerecord (= 8.0.3) + activestorage (= 8.0.3) + activesupport (= 8.0.3) bundler (>= 1.15.0) - railties (= 8.0.2) + railties (= 8.0.3) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) actionview (>= 5.0.1.rc1) @@ -229,20 +229,22 @@ GEM rails_stdout_logging rails_serve_static_assets (0.0.5) rails_stdout_logging (0.0.5) - railties (8.0.2) - actionpack (= 8.0.2) - activesupport (= 8.0.2) + railties (8.0.3) + actionpack (= 8.0.3) + activesupport (= 8.0.3) irb (~> 1.13) rackup (>= 1.0.0) rake (>= 12.2) thor (~> 1.0, >= 1.2.2) + tsort (>= 0.2) zeitwerk (~> 2.6) rainbow (3.1.1) rake (13.3.0) rb-readline (0.5.5) - rdoc (6.14.2) + rdoc (6.15.0) erb psych (>= 4.0.0) + tsort regexp_parser (2.11.3) reline (0.6.2) io-console (~> 0.5) @@ -296,6 +298,7 @@ GEM stringio (3.1.7) thor (1.4.0) timeout (0.4.3) + tsort (0.2.0) turbo-rails (2.0.17) actionpack (>= 7.1.0) railties (>= 7.1.0) @@ -307,7 +310,7 @@ GEM unicode-emoji (~> 4.1) unicode-emoji (4.1.0) uniform_notifier (1.18.0) - uri (1.0.3) + uri (1.0.4) useragent (0.16.11) websocket-driver (0.8.0) base64 @@ -341,7 +344,7 @@ DEPENDENCIES mysql2 propshaft puma - rails (= 8.0.2) + rails (= 8.0.3) rails-controller-testing rails-html-sanitizer rails_12factor diff --git a/bin/dev b/bin/dev index fc7cd1c..5f91c20 100755 --- a/bin/dev +++ b/bin/dev @@ -1,4 +1,2 @@ #!/usr/bin/env ruby - -# Start Rails server with defaults -exec "bin/rails", "server", *ARGV +exec "./bin/rails", "server", *ARGV diff --git a/config/application.rb b/config/application.rb index da911f9..cd7d380 100644 --- a/config/application.rb +++ b/config/application.rb @@ -55,5 +55,7 @@ module Wrestling # Set cache format version to a value supported by Rails 8.0 # Valid values are 7.0 or 7.1 config.active_support.cache_format_version = 7.1 + + config.load_defaults 8.0 end end diff --git a/config/initializers/assets.rb b/config/initializers/assets.rb new file mode 100644 index 0000000..4873244 --- /dev/null +++ b/config/initializers/assets.rb @@ -0,0 +1,7 @@ +# Be sure to restart your server when you modify this file. + +# Version of your assets, change this if you want to expire all your assets. +Rails.application.config.assets.version = "1.0" + +# Add additional assets to the asset load path. +# Rails.application.config.assets.paths << Emoji.images_path diff --git a/test/fixtures/tournament_job_statuses.yml b/test/fixtures/tournament_job_statuses.yml index 499b508..bdadf75 100644 --- a/test/fixtures/tournament_job_statuses.yml +++ b/test/fixtures/tournament_job_statuses.yml @@ -2,26 +2,4 @@ # This model requires tournament, job_name, and status fields -queued_job: - tournament: one - job_name: "Test Queued Job" - status: "Queued" - details: "Test job details" -running_job: - tournament: one - job_name: "Test Running Job" - status: "Running" - details: "Test running job details" - -errored_job: - tournament: one - job_name: "Test Errored Job" - status: "Errored" - details: "Test error message" - -another_tournament_job: - tournament: two - job_name: "Another Tournament Job" - status: "Running" - details: "Different tournament test" diff --git a/test/models/mat_test.rb b/test/models/mat_test.rb index 7d8999b..4026932 100644 --- a/test/models/mat_test.rb +++ b/test/models/mat_test.rb @@ -8,7 +8,7 @@ class MatTest < ActiveSupport::TestCase test "Mat validations" do mat = Mat.new assert_not mat.valid? - assert_equal [:name], mat.errors.attribute_names + assert_equal [:tournament, :name], mat.errors.attribute_names end end diff --git a/test/models/school_test.rb b/test/models/school_test.rb index b7ab6e7..3c7f6ee 100644 --- a/test/models/school_test.rb +++ b/test/models/school_test.rb @@ -8,7 +8,7 @@ class SchoolTest < ActiveSupport::TestCase test "School validations" do school = School.new assert_not school.valid? - assert_equal [:name], school.errors.attribute_names + assert_equal [:tournament, :name], school.errors.attribute_names end end diff --git a/test/models/weight_test.rb b/test/models/weight_test.rb index 62643aa..1028eb7 100644 --- a/test/models/weight_test.rb +++ b/test/models/weight_test.rb @@ -8,7 +8,7 @@ class WeightTest < ActiveSupport::TestCase test "Weight validations" do weight = Weight.new assert_not weight.valid? - assert_equal [:max], weight.errors.attribute_names + assert_equal [:tournament, :max], weight.errors.attribute_names end end diff --git a/test/models/wrestler_test.rb b/test/models/wrestler_test.rb index 4791c4a..a877a98 100644 --- a/test/models/wrestler_test.rb +++ b/test/models/wrestler_test.rb @@ -8,7 +8,7 @@ class WrestlerTest < ActiveSupport::TestCase test "Wrestler validations" do wrestler = Wrestler.new assert_not wrestler.valid? - assert_equal [:name, :weight_id, :school_id], wrestler.errors.attribute_names + assert_equal [:school, :weight, :name, :weight_id, :school_id], wrestler.errors.attribute_names end end