issue #8: update tests
This commit is contained in:
@@ -382,6 +382,7 @@ CAD;
|
||||
`
|
||||
|
||||
for n := 0; n < b.N; n++ {
|
||||
php7.Parse(bytes.NewBufferString(src), "test.php")
|
||||
php7parser := php7.NewParser(bytes.NewBufferString(src), "test.php")
|
||||
php7parser.Parse()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3166,7 +3166,9 @@ func TestPhp7(t *testing.T) {
|
||||
},
|
||||
}
|
||||
|
||||
actual, _, _, _ := php7.Parse(bytes.NewBufferString(src), "test.php")
|
||||
php7parser := php7.NewParser(bytes.NewBufferString(src), "test.php")
|
||||
php7parser.Parse()
|
||||
actual := php7parser.GetRootNode()
|
||||
assertEqual(t, expected, actual)
|
||||
}
|
||||
|
||||
@@ -3203,7 +3205,9 @@ func TestPhp5Strings(t *testing.T) {
|
||||
},
|
||||
}
|
||||
|
||||
actual, _, _, _ := php7.Parse(bytes.NewBufferString(src), "test.php")
|
||||
php7parser := php7.NewParser(bytes.NewBufferString(src), "test.php")
|
||||
php7parser.Parse()
|
||||
actual := php7parser.GetRootNode()
|
||||
assertEqual(t, expected, actual)
|
||||
}
|
||||
|
||||
@@ -3269,6 +3273,8 @@ CAD;
|
||||
},
|
||||
}
|
||||
|
||||
actual, _, _, _ := php7.Parse(bytes.NewBufferString(src), "test.php")
|
||||
php7parser := php7.NewParser(bytes.NewBufferString(src), "test.php")
|
||||
php7parser.Parse()
|
||||
actual := php7parser.GetRootNode()
|
||||
assertEqual(t, expected, actual)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user