rails/activemodel/test/models
RuhmUndAnsehen 3a3951a3a8 Fix ActiveModel::Conversion._to_partial_path not using a model's model_name.
The current implementation of _to_partial_path composes the part of two bits, `collection' and `element'.
ActiveModel::Name also contains these fields, and they are derived the same way _to_partial_path does it.
However, _to_partial_path doesn't use the information in model_name, and solely relies on its own computations instead.
This works for all standard cases, but not necessarily for models that provide a non-standard model_name.

This commit fixes that and has _to_partial_path use model_name if the class responds to it.
2023-08-28 22:05:34 +02:00
..
account.rb Use frozen string literal in activemodel/ 2017-07-16 20:11:16 +03:00
blog_post.rb Use frozen string literal in activemodel/ 2017-07-16 20:11:16 +03:00
contact.rb These test model accessors are public methods 2020-10-27 12:13:32 +09:00
custom_reader.rb Use frozen string literal in activemodel/ 2017-07-16 20:11:16 +03:00
helicopter.rb Fix ActiveModel::Conversion._to_partial_path not using a model's model_name. 2023-08-28 22:05:34 +02:00
person_with_validator.rb Raise deprecation for calling [:f] = 'b' or [:f] << 'b' 2019-03-31 22:59:12 +08:00
person.rb Add cases to test combining validation conditions 2017-11-06 23:07:51 +00:00
reply.rb Raise deprecation for calling [:f] = 'b' or [:f] << 'b' 2019-03-31 22:59:12 +08:00
sheep.rb Use frozen string literal in activemodel/ 2017-07-16 20:11:16 +03:00
topic.rb Add beginless range support to clusivity 2022-05-20 07:46:01 +10:00
track_back.rb Use frozen string literal in activemodel/ 2017-07-16 20:11:16 +03:00
user.rb Support password challenge via has_secure_password 2022-02-28 12:17:02 -06:00
visitor.rb Fix Ruby warnings tickled by the test suite 2018-06-30 10:20:45 +02:00