rubocop / rubocop-minitest

Code style checking for Minitest files.
https://docs.rubocop.org/rubocop-minitest
MIT License
144 stars 44 forks source link

Support `include?` aliases in `Minitest/AssertIncludes`? #315

Open vlad-pisanov opened 3 months ago

vlad-pisanov commented 3 months ago

Thought: should Minitest/AssertIncludes, Minitest/RefuteIncludes also detect common aliases of include?? Maybe via an option?

# bad
assert hash.include?(:foo) # currently supported ✔️ 
assert hash.key?(:foo)
assert hash.has_key?(:foo)
assert hash.member?(:foo)

# good
assert_includes hash, :foo