<@UVAR0DXP0> you closed off the rename inspectors ...
# kotest-contributors
s
@Emil Kantis you closed off the rename inspectors ticket, do you not want to do that anymore ?
e
There was very little response in favor of doing it (or not doing it for that matter), so I thought we could drop it
we could go about adding the
shouldForX
as aliases if you want?
s
My only reluctance was that the new names weren't much better imo
were we changing for the sake of it ?
but I agree that inspectors aren't that well known
Copy code
cities.shouldForOne { 
   it.shouldHaveName("Chicago")
   it.shouldHaveState("IL")
}
vs
Copy code
cities.forOne { 
   it.shouldHaveName("Chicago")
   it.shouldHaveState("IL")
}
I would be happy to add shouldForX as aliases to the existing matchers
e
I agree that
forOne
reads better and it’s a lot cleaner. A downside to the aliases would be consistency, and knowing what to prefer.. I still think it would be great for discoverability
s
The aliases won't hurt
Just don't deprecate the older ones
e
Could adding them as deprecated, with a
ReplaceWith
each respective
forX
version serve a purpose? Or do you think that would be bad practice?
s
I'm reluctant to keep deprecating things as people put years into tests
e
I mean that the added aliases would be flagged from the get-go.. 🙂
s
Oh i see
Interesting
What about a rule in the intellij plugin
e
Ah, that’s probably better
that can be toggled off, if user desires to, right
s
Yep
e
I really like that idea 🙂
s
Easy too
e
I remember seeing something in github regarding someone testing
Boolean?
like
Copy code
val x: Boolean? = null
x shouldNotBe true
where the plugin suggested that it should be replaced by
Copy code
x shouldBe false
Did you pick that one up or perhaps that could be.a good thing to check out to learn a bit about the intellij plugin?
s
I haven't done that one
It just needs deleting
e
Odd.. I can’t find it anymore either
s
It's a stupid rule
It's s good first ticket