-
Notifications
You must be signed in to change notification settings - Fork 203
increase JSON context DX #262
base: master
Are you sure you want to change the base?
Conversation
Imo you should add some testcases |
@OskarStark I added some tests. It's not 100% tested, but it's better than before ;) |
@@ -119,9 +128,15 @@ public function theJsonNodeShouldBeNull($node) | |||
*/ | |||
public function theJsonNodeShouldNotBeNull($node) | |||
{ | |||
$this->not(function () use ($node) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why you don’t use the not
wrapper here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right, I could have.
The only "issue" I see is that all those function need to mock or instantiate Mink instance, and I'm not really confident with that for now.
If I change back to the not, I can not easily test the function.
(The error message is Mink instance has not been set on Mink context class. Have you enabled the Mink Extension?
)
@sanpii up ? |
7191bc6
to
200aa8a
Compare
fix ReflectionClass::getClass deprecated (php8)
5de51bb
to
1f986cd
Compare
Improve error message, by telling with node is failing, the actual content and the expected value.