Project

General

Profile

Refactor #19131

Unpin minitest to permit later 5.x

Added by Dominic Cleal over 1 year ago. Updated 10 days ago.

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

Description

minitest was pinned to 5.1.x during #7230, the upgrade to Ruby on Rails 4.1. The exact reason is unclear (https://github.com/theforeman/foreman/pull/2870#discussion-diff-43727271).

It can be upgraded, but may require some changes to incorrect tests and fixes for deprecation warnings issued for Minitest 6 (e.g. assert_equal nil, [..] should be assert_nil).


Related issues

Related to Foreman Remote Execution - Bug #19360: Tests are failling with newest mintestClosed2017-04-24

Associated revisions

Revision edd5310f (diff)
Added by Dominic Cleal over 1 year ago

fixes #19131 - upgrade minitest to latest 5.x

- override minitest's `_` expectation method with the gettext method
- rename `location` let helper, conflicted with a minitest method name
- fix `assert_equal nil, [..]` deprecation warnings, prefer `assert nil`

Contains fixes for tests that leak data or behavioral changes between
tests, as the ordering of test cases is now randomised:

- remove Host/Nic class modifications in orchestration concern test
- move NotificationBlueprint seeding into test transaction, preventing
DB truncation in integration tests from removing the records
- ensure DBCleaner.start is called when in transaction mode to prevent
records leaking out of integration tests
- sort records for reliable comparisons in TaxonomyTest
- move IPs of BMC NIC factory objects to 1.0.0.0/8 to avoid duplicates
- remove duplicate SettingTest cache clear, missing rescue

History

#1 Updated by The Foreman Bot over 1 year ago

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

#2 Updated by Dominic Cleal over 1 year ago

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

#3 Updated by Ivan Necas about 1 year ago

  • Related to Bug #19360: Tests are failling with newest mintest added

#4 Updated by Marek Hulán 9 months ago

  • Legacy Backlogs Release (now unused) set to 240

Also available in: Atom PDF