The error below is displayed when $ rspec
is executed:
No known ORM was detected! Is ActiveRecord, DataMapper, Sequel, MongoMapper, Mongoid, Moped, or CouchPotato, Redis or Ohm loaded? (DatabaseCleaner::NoORMDetected)
This is a snippet from the spec_helper.rb file:
config.before(:suite) do
DatabaseCleaner.strategy = :transaction
DatabaseCleaner.clean_with(:truncation)
end
The Rails application in question uses ActiveRecord as the ORM and the documentation for Database Cleaner states that it checks for ActiveRecord first.
The Rails version for the application is 5.0.0.beta2
.
What is the cause of the error and how can this be fixed?