Open bitemyapp opened 8 years ago
I'm in favor. My only additional thought: maybe this functionality really belongs in hspec instead, and we could just leverage it from there.
@snoyberg mayhaps but yesod-test hadn't really been using hspec's stuff directly/properly (cf. assertEqual
) so I was trying to take the path of least resistance to getting this out there.
I'll do what I can to get it into hspec if I figure it out.
I have no objection if the functionality lives in yesod-test, your call.
Cf. #1255
There are libraries for pretty-printing, there are libraries for diffing. There's not a fantastically good reason we don't already have an
assertEqual
helper which doesn't both report the values that weren't equal but also shrink the report to a path and the individual components that weren't equal or which syntax highlights the components that were not alike (such as in a record).This one can be in a different function.