mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
9dc083f95d
Related to https://github.com/rails/rails/issues/44326 --- The changes introduced in [rails/rails#43421][] did not account for attempting to coerce the record with [#to_model][]. This commit resolves that issue and adds test coverage to guard against future regressions. Additionally, this adds tests to exercise `form_with` to ensure that it _does not_ call `#to_model` on its `model:` argument, since that was the behavior in [6.1.4.4][] [rails/rails#43421]: https://github.com/rails/rails/pull/43421 [#to_model]: https://edgeapi.rubyonrails.org/classes/ActiveModel/Conversion.html#method-i-to_model [6.1.4.4]: https://github.com/rails/rails/issues/44326#issuecomment-1029344241
206 B
206 B
-
Ensure models passed to
form_for
attempt to callto_model
.Sean Doyle
Please check 7-0-stable for previous changes.