You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Fixrails#54741 (comment)
- ### Problem
Custom minitest plugins that require tests to be loaded (such as
minitest-focus) may malfunction. This is due to a behaviour change
introduced in rails#54741.
### Context
Rails now load the test thanks to a custom plugin, but this creates
a caveat: Any plugins running prior than ours may need the tests
to be loaded.
The order of thing in a normal minitest setup is:
1) Test files are loaded
2) Minitest load plugins
3) Minitest initialize plugins
Before this patch it was:
1) Minitest load plugins
2) Minitest initialize plugins
3) Our plugin loads the test files.
The plugins are loaded/initialized by Minitest in a random order.
### Solution
I added a OptionsParser callback which get called at the very end of
the parsing process and is responsible to load the test files.
The order of thing is now:
1) Minitest load plugins
2) Test files are loaded
3) Minitest initialize the plugins
0 commit comments