You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[root@cdbha_test4 Gaea]# make test
go test -coverprofile=.coverage.out ./...
ok github.com/XiaoMi/Gaea/backend 0.006s coverage: 3.4% of statements
? github.com/XiaoMi/Gaea/cc [no test files]
? github.com/XiaoMi/Gaea/cc/proxy [no test files]
? github.com/XiaoMi/Gaea/cc/service [no test files]
ok github.com/XiaoMi/Gaea/cmd/gaea 0.009s coverage: 14.0% of statements
? github.com/XiaoMi/Gaea/cmd/gaea-cc [no test files]
? github.com/XiaoMi/Gaea/core [no test files]
? github.com/XiaoMi/Gaea/core/errors [no test files]
? github.com/XiaoMi/Gaea/log [no test files]
? github.com/XiaoMi/Gaea/log/xlog [no test files]
ok github.com/XiaoMi/Gaea/models 0.008s coverage: 77.3% of statements
ok github.com/XiaoMi/Gaea/models/etcd 0.004s coverage: 4.4% of statements
? github.com/XiaoMi/Gaea/models/file [no test files]
ok github.com/XiaoMi/Gaea/mysql 0.440s coverage: 34.3% of statements
ok github.com/XiaoMi/Gaea/parser 0.129s coverage: 84.1% of statements
ok github.com/XiaoMi/Gaea/parser/ast 0.052s coverage: 57.1% of statements
ok github.com/XiaoMi/Gaea/parser/auth 0.004s coverage: 0.0% of statements [no tests to run]
ok github.com/XiaoMi/Gaea/parser/format 0.003s coverage: 81.3% of statements
ok github.com/XiaoMi/Gaea/parser/model 0.006s coverage: 53.6% of statements
ok github.com/XiaoMi/Gaea/parser/opcode 0.003s coverage: 55.6% of statements
? github.com/XiaoMi/Gaea/parser/stmtctx [no test files]
ok github.com/XiaoMi/Gaea/parser/terror 0.349s coverage: 75.9% of statements
ok github.com/XiaoMi/Gaea/parser/tidb-types 0.035s coverage: 67.3% of statements
ok github.com/XiaoMi/Gaea/parser/tidb-types/json 0.007s coverage: 81.4% of statements
ok github.com/XiaoMi/Gaea/parser/tidb-types/parser_driver 0.005s coverage: 24.7% of statements
? github.com/XiaoMi/Gaea/parser/types [no test files]
--- FAIL: TestSelectKingshardDateYear (0.00s)
--- FAIL: TestSelectKingshardDateYear/select_from_tbl_ks_year_where_create_time<=1388505600 (0.00s)
plan_test.go:110: not equal, expect: map[slice-0:map[db_ks:[SELECT * FROM tbl_ks_year_2014 WHERE create_time<=1388505600]]], actual: map[]
--- FAIL: TestSelectKingshardDateYear/selectfrom_tbl_ks_year_where_create_time<=1388505600#01 (0.00s)
plan_test.go:110: not equal, expect: map[slice-0:map[db_ks:[SELECT * FROM tbl_ks_year_2014 WHERE create_time<=1388505600]]], actual: map[]
--- FAIL: TestSelectKingshardDateYear/selectfrom_tbl_ks_year_where_create_time>=1514736000 (0.00s)
plan_test.go:110: not equal, expect: map[slice-1:map[db_ks:[SELECT * FROM tbl_ks_year_2018 WHERE create_time>=1514736000 SELECT * FROM tbl_ks_year_2019 WHERE create_time>=1514736000]]], actual: map[slice-0:map[db_ks:[SELECT * FROM tbl_ks_year_2017 WHERE create_time>=1514736000]] slice-1:map[db_ks:[SELECT * FROM tbl_ks_year_2018 WHERE create_time>=1514736000 SELECT * FROM tbl_ks_year_2019 WHERE create_time>=1514736000]]]
--- FAIL: TestSelectKingshardDateYear/selectfrom_tbl_ks_year_where_create_time>=_1577808000 (0.00s)
plan_test.go:110: not equal, expect: map[], actual: map[slice-1:map[db_ks:[SELECT * FROM tbl_ks_year_2019 WHERE create_time>=1577808000]]]
panic: runtime error: index out of range [1] with length 1 [recovered]
panic: runtime error: index out of range [1] with length 1
goroutine 410 [running]:
testing.tRunner.func1(0xc000516400)
/usr/lib/golang/src/testing/testing.go:874 +0x3a3
panic(0xa58d60, 0xc00012c600)
/usr/lib/golang/src/runtime/panic.go:679 +0x1b2
github.com/XiaoMi/Gaea/proxy/plan.checkSQLs.func1(0xc0000203c0, 0xc000020cc0, 0xc00000e9c0)
/root/Gaea/proxy/plan/plan_test.go:151 +0x38a
github.com/XiaoMi/Gaea/proxy/plan.checkSQLs(0xc0000203c0, 0xc000020cc0, 0xa9bb49)
/root/Gaea/proxy/plan/plan_test.go:160 +0x40
github.com/XiaoMi/Gaea/proxy/plan.getTestFunc.func1(0xc000516400)
/root/Gaea/proxy/plan/plan_test.go:109 +0x408
testing.tRunner(0xc000516400, 0xc000369f40)
/usr/lib/golang/src/testing/testing.go:909 +0xc9
created by testing.(*T).Run
/usr/lib/golang/src/testing/testing.go:960 +0x350
FAIL github.com/XiaoMi/Gaea/proxy/plan 0.213s
ok github.com/XiaoMi/Gaea/proxy/router 0.018s coverage: 57.4% of statements
? github.com/XiaoMi/Gaea/proxy/sequence [no test files]
ok github.com/XiaoMi/Gaea/proxy/server 0.014s coverage: 3.2% of statements
ok github.com/XiaoMi/Gaea/stats 0.005s coverage: 70.2% of statements
ok github.com/XiaoMi/Gaea/stats/prometheus 0.039s coverage: 97.1% of statements
ok github.com/XiaoMi/Gaea/util 10.316s coverage: 49.3% of statements
ok github.com/XiaoMi/Gaea/util/bucketpool 0.539s coverage: 93.9% of statements
ok github.com/XiaoMi/Gaea/util/cache 0.003s coverage: 98.1% of statements
ok github.com/XiaoMi/Gaea/util/crypto 0.004s coverage: 69.7% of statements
ok github.com/XiaoMi/Gaea/util/hack 0.002s coverage: 55.0% of statements
? github.com/XiaoMi/Gaea/util/math [no test files]
ok github.com/XiaoMi/Gaea/util/requests 0.020s coverage: 48.5% of statements
ok github.com/XiaoMi/Gaea/util/sync2 0.029s coverage: 60.3% of statements
? github.com/XiaoMi/Gaea/util/testleak [no test files]
ok github.com/XiaoMi/Gaea/util/timer 0.827s coverage: 96.2% of statements
FAIL
make: *** [test] Error 1
The text was updated successfully, but these errors were encountered:
[root@cdbha_test4 Gaea]# make test
go test -coverprofile=.coverage.out ./...
ok github.com/XiaoMi/Gaea/backend 0.006s coverage: 3.4% of statements
? github.com/XiaoMi/Gaea/cc [no test files]
? github.com/XiaoMi/Gaea/cc/proxy [no test files]
? github.com/XiaoMi/Gaea/cc/service [no test files]
ok github.com/XiaoMi/Gaea/cmd/gaea 0.009s coverage: 14.0% of statements
? github.com/XiaoMi/Gaea/cmd/gaea-cc [no test files]
? github.com/XiaoMi/Gaea/core [no test files]
? github.com/XiaoMi/Gaea/core/errors [no test files]
? github.com/XiaoMi/Gaea/log [no test files]
? github.com/XiaoMi/Gaea/log/xlog [no test files]
ok github.com/XiaoMi/Gaea/models 0.008s coverage: 77.3% of statements
ok github.com/XiaoMi/Gaea/models/etcd 0.004s coverage: 4.4% of statements
? github.com/XiaoMi/Gaea/models/file [no test files]
ok github.com/XiaoMi/Gaea/mysql 0.440s coverage: 34.3% of statements
ok github.com/XiaoMi/Gaea/parser 0.129s coverage: 84.1% of statements
ok github.com/XiaoMi/Gaea/parser/ast 0.052s coverage: 57.1% of statements
ok github.com/XiaoMi/Gaea/parser/auth 0.004s coverage: 0.0% of statements [no tests to run]
ok github.com/XiaoMi/Gaea/parser/format 0.003s coverage: 81.3% of statements
ok github.com/XiaoMi/Gaea/parser/model 0.006s coverage: 53.6% of statements
ok github.com/XiaoMi/Gaea/parser/opcode 0.003s coverage: 55.6% of statements
? github.com/XiaoMi/Gaea/parser/stmtctx [no test files]
ok github.com/XiaoMi/Gaea/parser/terror 0.349s coverage: 75.9% of statements
ok github.com/XiaoMi/Gaea/parser/tidb-types 0.035s coverage: 67.3% of statements
ok github.com/XiaoMi/Gaea/parser/tidb-types/json 0.007s coverage: 81.4% of statements
ok github.com/XiaoMi/Gaea/parser/tidb-types/parser_driver 0.005s coverage: 24.7% of statements
? github.com/XiaoMi/Gaea/parser/types [no test files]
--- FAIL: TestSelectKingshardDateYear (0.00s)
--- FAIL: TestSelectKingshardDateYear/select_from_tbl_ks_year_where_create_time<=1388505600 (0.00s)
plan_test.go:110: not equal, expect: map[slice-0:map[db_ks:[SELECT * FROM
tbl_ks_year_2014
WHEREcreate_time
<=1388505600]]], actual: map[]--- FAIL: TestSelectKingshardDateYear/selectfrom_tbl_ks_year_where_create_time<=1388505600#01 (0.00s)
plan_test.go:110: not equal, expect: map[slice-0:map[db_ks:[SELECT * FROM
tbl_ks_year_2014
WHEREcreate_time
<=1388505600]]], actual: map[]--- FAIL: TestSelectKingshardDateYear/selectfrom_tbl_ks_year_where_create_time>=1514736000 (0.00s)
plan_test.go:110: not equal, expect: map[slice-1:map[db_ks:[SELECT * FROM
tbl_ks_year_2018
WHEREcreate_time
>=1514736000 SELECT * FROMtbl_ks_year_2019
WHEREcreate_time
>=1514736000]]], actual: map[slice-0:map[db_ks:[SELECT * FROMtbl_ks_year_2017
WHEREcreate_time
>=1514736000]] slice-1:map[db_ks:[SELECT * FROMtbl_ks_year_2018
WHEREcreate_time
>=1514736000 SELECT * FROMtbl_ks_year_2019
WHEREcreate_time
>=1514736000]]]--- FAIL: TestSelectKingshardDateYear/selectfrom_tbl_ks_year_where_create_time>=_1577808000 (0.00s)
plan_test.go:110: not equal, expect: map[], actual: map[slice-1:map[db_ks:[SELECT * FROM
tbl_ks_year_2019
WHEREcreate_time
>=1577808000]]]panic: runtime error: index out of range [1] with length 1 [recovered]
panic: runtime error: index out of range [1] with length 1
goroutine 410 [running]:
testing.tRunner.func1(0xc000516400)
/usr/lib/golang/src/testing/testing.go:874 +0x3a3
panic(0xa58d60, 0xc00012c600)
/usr/lib/golang/src/runtime/panic.go:679 +0x1b2
github.com/XiaoMi/Gaea/proxy/plan.checkSQLs.func1(0xc0000203c0, 0xc000020cc0, 0xc00000e9c0)
/root/Gaea/proxy/plan/plan_test.go:151 +0x38a
github.com/XiaoMi/Gaea/proxy/plan.checkSQLs(0xc0000203c0, 0xc000020cc0, 0xa9bb49)
/root/Gaea/proxy/plan/plan_test.go:160 +0x40
github.com/XiaoMi/Gaea/proxy/plan.getTestFunc.func1(0xc000516400)
/root/Gaea/proxy/plan/plan_test.go:109 +0x408
testing.tRunner(0xc000516400, 0xc000369f40)
/usr/lib/golang/src/testing/testing.go:909 +0xc9
created by testing.(*T).Run
/usr/lib/golang/src/testing/testing.go:960 +0x350
FAIL github.com/XiaoMi/Gaea/proxy/plan 0.213s
ok github.com/XiaoMi/Gaea/proxy/router 0.018s coverage: 57.4% of statements
? github.com/XiaoMi/Gaea/proxy/sequence [no test files]
ok github.com/XiaoMi/Gaea/proxy/server 0.014s coverage: 3.2% of statements
ok github.com/XiaoMi/Gaea/stats 0.005s coverage: 70.2% of statements
ok github.com/XiaoMi/Gaea/stats/prometheus 0.039s coverage: 97.1% of statements
ok github.com/XiaoMi/Gaea/util 10.316s coverage: 49.3% of statements
ok github.com/XiaoMi/Gaea/util/bucketpool 0.539s coverage: 93.9% of statements
ok github.com/XiaoMi/Gaea/util/cache 0.003s coverage: 98.1% of statements
ok github.com/XiaoMi/Gaea/util/crypto 0.004s coverage: 69.7% of statements
ok github.com/XiaoMi/Gaea/util/hack 0.002s coverage: 55.0% of statements
? github.com/XiaoMi/Gaea/util/math [no test files]
ok github.com/XiaoMi/Gaea/util/requests 0.020s coverage: 48.5% of statements
ok github.com/XiaoMi/Gaea/util/sync2 0.029s coverage: 60.3% of statements
? github.com/XiaoMi/Gaea/util/testleak [no test files]
ok github.com/XiaoMi/Gaea/util/timer 0.827s coverage: 96.2% of statements
FAIL
make: *** [test] Error 1
The text was updated successfully, but these errors were encountered: