Closed zw963 closed 4 years ago
Rails version: 5.0.6
broken test is here:
require 'test_helper'
class RenewalRateMonthlyReportTest < ActiveSupport::TestCase
should belong_to :reportable
end
test_helper is here:
ENV['RAILS_ENV'] ||= 'test'
require File.expand_path('../../config/environment', __FILE__)
require 'rails/test_help'
class ActiveSupport::TestCase
# Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order.
# fixtures :all
# Add more helper methods to be used by all tests here...
include FactoryBot::Syntax::Methods
include Devise::Test::IntegrationHelpers
end
Hey, I'm so so sorry for the late update on this. I just released shoulda 4.0.0.rc1. Can you try it out and see if it works for you?
Sorry, old project not support ruby 2.4.0, can't test on it.
Fetching shoulda-context 2.0.0.rc2
Installing shoulda-context 2.0.0.rc2
Fetching shoulda-matchers 4.1.2
Installing shoulda-matchers 4.1.2
Gem::InstallError: shoulda-matchers requires Ruby version >= 2.4.0.
An error occurred while installing shoulda-matchers (4.1.2), and Bundler cannot continue.
Make sure that gem install shoulda-matchers -v '4.1.2'
succeeds before bundling.
Ah I see. Yes, Ruby 2.3.x was end-of-lifed earlier this year, so you might want to see if you can upgrade: https://www.ruby-lang.org/en/news/2018/10/17/ruby-2-3-8-released/. Sorry about that.
I just released Shoulda 4.0.0. This upgrades the dependency on shoulda-context to 2.0.0 as well as shoulda-matchers to ~> 4.0, both of which add proper support for Rails 5 and 6. Closing this now, but if you see any more issues don't hesitate to file them!
When add model should spec, got following error: