|
1 | 1 | package parse
|
2 | 2 |
|
3 | 3 | import (
|
| 4 | + "math" |
4 | 5 | "testing"
|
5 | 6 |
|
6 | 7 | "github.com/src-d/go-mysql-server/sql/expression"
|
@@ -1191,6 +1192,23 @@ var fixtures = map[string]sql.Node{
|
1191 | 1192 | []sql.Expression{},
|
1192 | 1193 | plan.NewUnresolvedTable("foo", ""),
|
1193 | 1194 | ),
|
| 1195 | + `SELECT -128, 127, 255, -32768, 32767, 65535, -2147483648, 2147483647, 4294967295, -9223372036854775808, 9223372036854775807, 18446744073709551615`: plan.NewProject( |
| 1196 | + []sql.Expression{ |
| 1197 | + expression.NewLiteral(int8(math.MinInt8), sql.Int8), |
| 1198 | + expression.NewLiteral(int8(math.MaxInt8), sql.Int8), |
| 1199 | + expression.NewLiteral(uint8(math.MaxUint8), sql.Uint8), |
| 1200 | + expression.NewLiteral(int16(math.MinInt16), sql.Int16), |
| 1201 | + expression.NewLiteral(int16(math.MaxInt16), sql.Int16), |
| 1202 | + expression.NewLiteral(uint16(math.MaxUint16), sql.Uint16), |
| 1203 | + expression.NewLiteral(int32(math.MinInt32), sql.Int32), |
| 1204 | + expression.NewLiteral(int32(math.MaxInt32), sql.Int32), |
| 1205 | + expression.NewLiteral(uint32(math.MaxUint32), sql.Uint32), |
| 1206 | + expression.NewLiteral(int64(math.MinInt64), sql.Int64), |
| 1207 | + expression.NewLiteral(int64(math.MaxInt64), sql.Int64), |
| 1208 | + expression.NewLiteral(uint64(math.MaxUint64), sql.Uint64), |
| 1209 | + }, |
| 1210 | + plan.NewUnresolvedTable("dual", ""), |
| 1211 | + ), |
1194 | 1212 | }
|
1195 | 1213 |
|
1196 | 1214 | func TestParse(t *testing.T) {
|
|
0 commit comments