Details
Description
In the following code
def j = "5" assert 5 == j Assertion failed: assert 5 == j | | | 5 false
it is confusing to understand why assert fails if no types are displayed. Variables compared may be different but their toString() representations used by assert error message may be identical.
Another example I had was:
assert pomSize == project.properties.pomSize | | | | | 2607 | | | 2607 | | [pomSize:2607, gmavenVersion:1.3] | MavenProject: com.goldin:groovymag.listing-1:12.2010 @ E:\Projects\GroovyMag\December-2010\Listing-1\pom.xml false
Here I had a number 2607 on the left, but a String "2607" on the right.
I suggest to add types of variables compared in assert.
Peter, I think you mentioned it somewhere already... why again did you not mark Strings especially again?