Miloslav Hůla

Results 108 comments of Miloslav Hůla

I really like this idea. It's about year and half I created something similar in my local repo. But as a Tester's plugin and on high layer that this. Actually,...

Thinking about API, just for discussion. Not sure, there should be class `Snapshot` in user space. Looks like `Assert::snapshot()` is sufficient. IMHO the method should assert always as `Assert::same()`, not...

We can wake this up. What about this summary: - if some snapshot is missing, assertion fails - calling `tester --snapshot tests` generates fresh new snapshots for all run tests...

Maybe add `Assert::matchRE()` and `Assert::outputMatchRE()`?

Uff, sorry, I just wated to send comment, not to start review. Just clicked the first green button I saw :)

I'm in 👍 I proposed similar thing, `Assert::block(callable ...)`, in the past, but I cannot find it now. And I can't recall why we didn't use it :o)

> switch to turn off output I think this can be controlled by the same option as color output is.

> The function is only created if it does not exist, which should prevent collisions. Maybe it could be controlled in any other way. Just thinking a loud... What about...

> switch whether to continue to the next test() function if assertion fails Something like deferred fail? Maybe always when run directly by `php test.phpt` and not by Runner?

I would stay with yellow. IMHO, when showing diff, there is no reason for red/green. Cannot say old/new, correct/wrong because maybe test needs to be updated. The inverse of difference...