scanner: split float and number tests

This commit is contained in:
Fatih Arslan 2015-10-05 13:38:53 +03:00
parent 6e23b0404d
commit 9a71fdff07

View File

@ -165,6 +165,13 @@ func TestNumber(t *testing.T) {
{token.NUMBER, "0X42"},
{token.NUMBER, "0X123456789abcDEF"},
{token.NUMBER, "0X" + f100},
}
testTokenList(t, tokenList)
}
func TestFloat(t *testing.T) {
var tokenList = []tokenPair{
{token.FLOAT, "0."},
{token.FLOAT, "1."},
{token.FLOAT, "42."},