Project

General

Profile

Refactor #13879

Load mocha/minitest integration explicitly in test_helper

Added by Dominic Cleal about 6 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Tests
Target version:
Difficulty:
Triaged:
Bugzilla link:
Fixed in Releases:
Found in Releases:

Description

https://github.com/rails/rails/commit/fd6aaaa in Rails 4.2 will remove automatic loading of mocha from the Rails test helper, as it's expected that applications have an explicit dependency on it anyway if they want to use it.

Without it, mocha methods simply don't exist and tests fail with:

NoMethodError: undefined method `any_instance' for #<Class:0x000000070d2670>
    app/models/host.rb:15:in `method_missing'
    test/test_helper.rb:196:in `disable_orchestration'

Related issues

Blocks Foreman - Feature #13244: Upgrade Ruby on Rails to 4.2Closed2016-01-15

Associated revisions

Revision 8a7d34da (diff)
Added by Dominic Cleal about 6 years ago

fixes #13879 - load mocha/minitest integration explicitly

rails/rails@fd6aaaa removed automatic loading of mocha in Rails 4.2
from rails/test_help.

History

#1 Updated by Dominic Cleal about 6 years ago

#2 Updated by The Foreman Bot about 6 years ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/3232 added

#3 Updated by Dominic Cleal about 6 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

#4 Updated by Dominic Cleal about 6 years ago

  • Legacy Backlogs Release (now unused) set to 136

Also available in: Atom PDF