Improve message for (==?) operator
After seeing how nice HUnit formats the error message on failed 'assertEqual', I think we can do better with ==?. Currently it says (on one line): "Expected equality, but 1 /= 2". This patch changes the code to format it similar to HUnit: Expected equality, but got mismatch expected: 1 but got: 2 (on three lines). This makes it more clear what is the expected and what is the wrong value. A few tests have been modified to ensure that the expected value is the second argument to ==?. This is different than HUnit, but makes more sense in the operator version (I think). Signed-off-by:Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
Loading
Please register or sign in to comment