-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Closed
Description
It's not a secret that all asserts in PHPUnit are in fact static methods, but everyone are using them as they are not, even official documentation.
I think I understand the reasons, why they were made static in first place, probably it is related to performance (btw, do other reasons exists for that?).
But in my own opinion, if they are static, we should use them as we use other static methods to make our code cleaner.
This means using:
self::assertTrue(...);
instead of:
$this->assertTrue(...);
Can anyone give me a good reason why we shouldn't?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels