diff --git a/Gemfile b/Gemfile index 5e80a7497..e8c7dd32a 100644 --- a/Gemfile +++ b/Gemfile @@ -113,8 +113,8 @@ end group :test do gem 'test-unit', '~> 3.0' - gem 'shoulda', '~> 3.5' - gem 'shoulda-matchers', '~> 2.0' + gem 'shoulda', '~> 4.0.0' + gem 'shoulda-matchers', '~> 4.4.0' gem 'minitest-reporters' gem 'valid_attribute' gem 'factory_bot_rails' diff --git a/Gemfile.lock b/Gemfile.lock index e5b8607c7..8aec52905 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -361,12 +361,12 @@ GEM ruby_http_client (~> 3.4) sexp_processor (4.15.0) shellany (0.0.1) - shoulda (3.5.0) - shoulda-context (~> 1.0, >= 1.0.1) - shoulda-matchers (>= 1.4.1, < 3.0) - shoulda-context (1.2.2) - shoulda-matchers (2.8.0) - activesupport (>= 3.0.0) + shoulda (4.0.0) + shoulda-context (~> 2.0) + shoulda-matchers (~> 4.0) + shoulda-context (2.0.0) + shoulda-matchers (4.4.1) + activesupport (>= 4.2.0) sidekiq (6.0.7) connection_pool (>= 2.2.2) rack (~> 2.0) @@ -408,7 +408,7 @@ GEM turbolinks (5.2.1) turbolinks-source (~> 5.2) turbolinks-source (5.2.0) - tzinfo (1.2.8) + tzinfo (1.2.9) thread_safe (~> 0.1) uglifier (4.2.0) execjs (>= 0.3.0, < 3) @@ -487,8 +487,8 @@ DEPENDENCIES selectize-rails selenium-webdriver sendgrid-actionmailer - shoulda (~> 3.5) - shoulda-matchers (~> 2.0) + shoulda (~> 4.0.0) + shoulda-matchers (~> 4.4.0) sidekiq (< 7) sidekiq-cron (~> 1.1) simple_form diff --git a/test/models/questionnaire_test.rb b/test/models/questionnaire_test.rb index 7cf590185..4fa2d3863 100644 --- a/test/models/questionnaire_test.rb +++ b/test/models/questionnaire_test.rb @@ -5,7 +5,7 @@ class QuestionnaireTest < ActiveSupport::TestCase should belong_to :user should belong_to :school - should belong_to :bus_list + should belong_to(:bus_list).optional should have_and_belong_to_many :agreements should validate_uniqueness_of :user_id diff --git a/test/models/user_test.rb b/test/models/user_test.rb index 1b288f72f..a5956b0a0 100644 --- a/test/models/user_test.rb +++ b/test/models/user_test.rb @@ -7,7 +7,7 @@ class UserTest < ActiveSupport::TestCase should strip_attribute :last_name should strip_attribute :email - should validate_uniqueness_of :email + should validate_uniqueness_of(:email).ignoring_case_sensitivity should validate_presence_of :first_name should validate_presence_of :last_name diff --git a/test/test_helper.rb b/test/test_helper.rb index 2d3f333a8..4208de352 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -51,3 +51,10 @@ class ActiveSupport::TestCase class ActionController::TestCase include Devise::Test::ControllerHelpers end + +Shoulda::Matchers.configure do |config| + config.integrate do |with| + with.test_framework :minitest + with.library :rails + end +end diff --git a/vendor/cache/shoulda-3.5.0.gem b/vendor/cache/shoulda-3.5.0.gem deleted file mode 100644 index a79d90d9d..000000000 Binary files a/vendor/cache/shoulda-3.5.0.gem and /dev/null differ diff --git a/vendor/cache/shoulda-4.0.0.gem b/vendor/cache/shoulda-4.0.0.gem new file mode 100644 index 000000000..3f271dc15 Binary files /dev/null and b/vendor/cache/shoulda-4.0.0.gem differ diff --git a/vendor/cache/shoulda-context-1.2.2.gem b/vendor/cache/shoulda-context-1.2.2.gem deleted file mode 100644 index 9f93a904e..000000000 Binary files a/vendor/cache/shoulda-context-1.2.2.gem and /dev/null differ diff --git a/vendor/cache/shoulda-context-2.0.0.gem b/vendor/cache/shoulda-context-2.0.0.gem new file mode 100644 index 000000000..ced302fb3 Binary files /dev/null and b/vendor/cache/shoulda-context-2.0.0.gem differ diff --git a/vendor/cache/shoulda-matchers-2.8.0.gem b/vendor/cache/shoulda-matchers-2.8.0.gem deleted file mode 100644 index 950440762..000000000 Binary files a/vendor/cache/shoulda-matchers-2.8.0.gem and /dev/null differ diff --git a/vendor/cache/shoulda-matchers-4.4.1.gem b/vendor/cache/shoulda-matchers-4.4.1.gem new file mode 100644 index 000000000..6695d1a87 Binary files /dev/null and b/vendor/cache/shoulda-matchers-4.4.1.gem differ diff --git a/vendor/cache/tzinfo-1.2.9.gem b/vendor/cache/tzinfo-1.2.9.gem new file mode 100644 index 000000000..9f596f54b Binary files /dev/null and b/vendor/cache/tzinfo-1.2.9.gem differ