Open JonRowe opened 3 years ago
A WIP attempt to get rid of WKWN in rspec-core
https://github.com/rspec/rspec-core/commit/684b58411467aa551f00f0963de4276b8105eabf
I've been running it on Ruby 3.0, and the spec fails with something like foo: keyword missing
for those lines where we pass a hash:
include_examples "...", { foo: "..." }
My approach to try to split args and use
**kwargs
for delegation is incorrect and needs to be phased out in 3.x and this module removed in 4.x. The problem is that arguments that implementto_hash
are wrongly detected (with no way to know they are not) and converted. Onlyruby2_keywords
delegation is safe.See https://github.com/rspec/rspec-expectations/issues/1241 as an example of this issue.