rails--rails/activestorage/test/models
eileencodes 9766eb4a83
Fix tests for minitest 5.16
In minitest/minitest@6e06ac9 minitest changed such that it now accepts
`kwargs` instead of requiring kwargs to be shoved into the args array.
This is a good change but required some updates to our test code to get
the new version of minitest passing.

Changes are as follows:

1) Lock minitest to 5.15 for Ruby 2.7. We don't love this change but
it's pretty difficult to get 2.7 and 3.0 to play nicely together with
the new kwargs changes. Dropping 2.7 support isn't an option right
now for Rails. This is safe because all of the code changes here are
internal methods to Rails like assert_called_with. Applications
shouldn't be consuming them as they are no-doc'd.
2) Update the `assert_called_with` method to take any kwargs but also
the returns kwarg.
3) Update callers of `assert_called_with` to move the kwargs outside the
args array.
4) Update the message from marshaled exceptions. In 5.16 the exception
message is "result not reported" instead of "Wrapped undumpable
exception".

Co-authored-by: Matthew Draper <matthew@trebex.net>
2022-06-23 08:32:11 -04:00
..
attached Fix tests for minitest 5.16 2022-06-23 08:32:11 -04:00
attachment_test.rb Enable `Style/ExplicitBlockArgument` cop 2021-09-05 17:06:19 +02:00
blob_test.rb Fix tests for minitest 5.16 2022-06-23 08:32:11 -04:00
filename_test.rb Enable `Performance/UnfreezeString` cop 2018-09-23 08:56:55 +09:00
presence_validation_test.rb Store newly-uploaded files on save rather than assignment 2018-07-07 23:25:33 -04:00
preview_test.rb Make vips the default variant processor for new apps 2021-07-14 14:26:43 -03:00
reflection_test.rb Extend audio_tag and video_tag to accept Active Storage attachments. 2022-03-14 02:05:37 -03:00
representation_test.rb Make vips the default variant processor for new apps 2021-07-14 14:26:43 -03:00
strict_loading_test.rb Add strict loading for active storage 2020-11-16 22:09:15 +08:00
variant_test.rb Treat `image/bmp` as a valid content type 2022-04-19 08:08:16 +10:00
variant_with_record_test.rb Active Storage eager loading: support more methods 2021-12-08 13:54:37 -06:00