I’m trying to add Rails 5 support to an engine which (among other things) has a generator for controller tests.
I’ve ran into the keyword arguments deprecation warning at the bottom of this e-mail, and I’m in a bind now. If I use keyword arguments to get rid of the warnings, I lose Rails 4 compatibility.
So far, I’ve managed to write tests that work in current Rails and previous Rails, and I hope I’ll be able to do that in the future. Is there any chance that the keyword arguments will be backported to Rails 4 via a gem, like strong_parameters were backported to Rails 3?
I don’t think it is necessary. You can still use the same syntax with Rails 4 and Rails 5, you will only see deprecations warnings, and I believe it is acceptable in this case.
I still feel like having a gem that give support for 4.2 would be nice though, as it would suck when Rails 5.1 comes out … but again, it’s possible that you’ll switch to kwargs syntax by that point and only support 5.0 and 5.1