Skip to content

Minitest / Shoulda Gem errors #23

Description

@eliaszica

I'm having a issue similar to #15 in my Rails 5 application models tests with Minitest and Shoulda gem. So I inserted this code block (as issue #15's author suggests) in my "schema_associations.rb", and the tests now run smoothly:

if Rails.env.test?
   [Class1, Class2, Class3].each do |c|
      c.reflect_on_all_associations
   end
end

For now I'm happy with this solution, and maybe this scenario can help you to find some improvement to schema_associations gem (I hope so).

Thank you, this gem is awesome!

Elias

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions