Revised error formatting, fixed tests

This commit is contained in:
eanderton
2014-08-06 08:15:05 -04:00
parent 7d9a3c25bd
commit 6db660fed5
2 changed files with 26 additions and 21 deletions
+2 -2
View File
@@ -249,12 +249,12 @@ func TestImplicitDeclarationBefore(t *testing.T) {
func TestFloatsWithoutLeadingZeros(t *testing.T) {
_, err := Load("a = .42")
if err.Error() != "cannot start float with a dot" {
if err.Error() != "(1, 4): cannot start float with a dot" {
t.Error("Bad error message:", err.Error())
}
_, err = Load("a = -.42")
if err.Error() != "cannot start float with a dot" {
if err.Error() != "(1, 5): cannot start float with a dot" {
t.Error("Bad error message:", err.Error())
}
}