Skip to content

Commit 2a19617

Browse files
committed
add test code
1 parent 7db1822 commit 2a19617

30 files changed

+2431
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
testId,containerType,containerName,rowKeyList,GS_TYPE_STRING,GS_TYPE_BOOL,GS_TYPE_DOUBLe,queryCommand,expectedOutput
2+
BS-001-Container_basic_scenario-001,GS_CONTAINER_COLLECTION,Abc_123,[10;20;30],abc,True,1.1,select MIN(a_9),0
3+
BS-001-Container_basic_scenario-002,GS_CONTAINER_COLLECTION,Abc_124,[10;20;3.3],abc,True,1.1,select MAX(za),1
4+
BS-001-Container_basic_scenario-003,GS_CONTAINER_COLLECTION,Abc_125,[10;20;30],abc,False,False,select MIN(a_9),1
5+
BS-001-Container_basic_scenario-004,GS_CONTAINER_TIME_SERIES,Abc_126,[2018-12-01T10:00:00.000Z;2018-12-01T10:10:00.000Z;2018-12-01T10:20:00.000Z],abc,True,1.1,select MAX(za),0
6+
BS-001-Container_basic_scenario-005,GS_CONTAINER_TIME_SERIES,Abc_127,[2018-12-01T10:00:00.000Z;2018-12-01T10:10:00.000Z;3.3],abc,True,1.1,select MIN(a_91),1
7+
BS-001-Container_basic_scenario-006,GS_CONTAINER_TIME_SERIES,Abc_128,[2018-12-01T10:00:00.000Z;2018-12-01T10:10:00.000Z;2018-12-01T10:20:00.000Z],abc,False,1,select MAX(za1),1
8+
BS-001-Container_basic_scenario-007,GS_CONTAINER_TIME_SERIES,Abc_128<.>/?;:[]{}~`!@#$%^&*(),[2018-12-01T10:00:00.000Z;2018-12-01T10:10:00.000Z;2018-12-01T10:20:00.000Z],abc,False,1,select MAX(za),1
9+
BS-001-Container_basic_scenario-008,GS_CONTAINER_TIME_SERIES,Abc_128'リング,[2018-12-01T10:00:00.000Z;2018-12-01T10:10:00.000Z;2018-12-01T10:20:00.000Z],abc,False,1,select MAX(za),1
10+
BS-001-Container_basic_scenario-009,GS_CONTAINER_TIME_SERIES,Abc_128リング,[2018-12-01T10:00:00.000Z;2018-12-01T10:10:00.000Z;2018-12-01T10:20:00.000Z],abc,False,1,select MAX(za),1
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
testId, containerType,GS_TYPE_STRING, GS_TYPE_TIMESTAMP, GS_TYPE_BYTE, GS_TYPE_SHORT, GS_TYPE_INTEGER, GS_TYPE_BOOL, GS_TYPE_FLOAT, GS_TYPE_DOUBLE, GS_TYPE_BLOB, expectedOutput
2+
BS-004-Container_put_get-001,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,9.9,abc,0
3+
BS-004-Container_put_get-002,GS_CONTAINER_TIME_SERIES,abc,2018-12-01T10:20:00.000Z,127,32767,2147483647,False,1.1,9.9,[1;2;3],0
4+
BS-004-Container_put_get-003,GS_CONTAINER_TIME_SERIES,abc,9999-12-31T23:59:59.999Z,127,32767,2147483647,True,1.1,9.9,[1;2;3],0
5+
BS-004-Container_put_get-004,GS_CONTAINER_TIME_SERIES,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,9.9,[1;2;3],0
6+
BS-004-Container_put_get-005,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,9.9,ABC,0
7+
BS-004-Container_put_get-006,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,9.9,[1;2;3],0
8+
BS-004-Container_put_get-007,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,9.9,[1;2;3],0
9+
BS-004-Container_put_get-008,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,9.9,[1;2;3],0
10+
BS-004-Container_put_get-009,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,99,1.1,9.9,[1;2;3],0
11+
BS-004-Container_put_get-010,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,9.9,[1;2;3],0
12+
BS-004-Container_put_get-011,GS_CONTAINER_COLLECTION,abc,1970-01-01T00:00:00.000Z,127,32767,2147483647,True,1.1,100,[1;2;3],0
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
testId, containerType, columnInfo, indexType, expectedOutput
2+
BS-005-Container_index_create_drop-001,GS_CONTAINER_COLLECTION,1_a:GS_TYPE_INTEGER,GS_INDEX_FLAG_HASH,0
3+
BS-005-Container_index_create_drop-002,GS_CONTAINER_TIME_SERIES,Z0:GS_TYPE_BYTE,,0
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
testId, containerType, query, expectedOutput
2+
BS-007-Aggregation_with_double_timestamp-001,GS_CONTAINER_COLLECTION,select MIN(a_9),0
3+
BS-007-Aggregation_with_double_timestamp-002,GS_CONTAINER_COLLECTION,select MAX(za),0
4+
BS-007-Aggregation_with_double_timestamp-003,GS_CONTAINER_COLLECTION,select MIN(A00) from not_exist,1
5+
BS-007-Aggregation_with_double_timestamp-004,GS_CONTAINER_COLLECTION,select MAX(A00) from not_exist,1
6+
BS-007-Aggregation_with_double_timestamp-005,GS_CONTAINER_TIME_SERIES,select MIN(a_9),0
7+
BS-007-Aggregation_with_double_timestamp-006,GS_CONTAINER_TIME_SERIES,select MAX(za),0
8+
BS-007-Aggregation_with_double_timestamp-007,GS_CONTAINER_TIME_SERIES,select MIN(A00) from not_exist,1
9+
BS-007-Aggregation_with_double_timestamp-008,GS_CONTAINER_TIME_SERIES,select MAX(A00) from not_exist,1
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
testId, containerType, rowKey, rowKeyType, GS_TYPE_BYTE, GS_TYPE_SHORT, GS_TYPE_BOOL, GS_TYPE_FLOAT , GS_TYPE_DOUBLE, GS_TYPE_BLOB, expectedOutput
2+
BS-008-Container_put_get_remove-001,GS_CONTAINER_COLLECTION,abc,string,127,32767,True,1.1,9.9,ABC,0
3+
BS-008-Container_put_get_remove-002,GS_CONTAINER_COLLECTION,2147483647,integer,32,767,False,1.1,9.9,[1;2;3],0
4+
BS-008-Container_put_get_remove-003,GS_CONTAINER_COLLECTION,9223372036854775807,long,32,767,True,1.1,9.9,[1;2;3],0
5+
BS-008-Container_put_get_remove-004,GS_CONTAINER_TIME_SERIES,9999-12-31T23:59:59.999Z,timestamp,32,767,True,1.1,9.9,[1;2;3],0
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
testId,ContainerType,RowKeyType,RowKey,GS_TYPE_STRING,GS_TYPE_BOOL,GS_TYPE_BYTE,GS_TYPE_SHORT,GS_TYPE_INTEGER,GS_TYPE_LONG,GS_TYPE_FLOAT,GS_TYPE_DOUBLE,GS_TYPE_BLOB,expectedOutput
2+
BS-009-RowSet_manual_commit-001,GS_CONTAINER_COLLECTION,string,abc,abc,True,127,32767,2147483647,3000000000,1.1,9.9,[1;2;3],0
3+
BS-009-RowSet_manual_commit-002,GS_CONTAINER_COLLECTION,integer,99,abc,True,127,32767,2147483647,3000000000,1.2,9.10,[1;2;3],0
4+
BS-009-RowSet_manual_commit-003,GS_CONTAINER_COLLECTION,long,2147483647,abc,True,127,32767,2147483647,3000000000,1.3,9.11,[1;2;3],0
5+
BS-009-RowSet_manual_commit-004,GS_CONTAINER_TIME_SERIES,timestamp,1970-01-01T00:00:00.000Z,abc,True,127,32767,2147483647,3000000000,1.4,9.12,[1;2;3],0
6+
BS-009-RowSet_manual_commit-005,GS_CONTAINER_COLLECTION,string,1.1,abc,True,127,32767,2147483647,3000000000,1.5,9.13,[1;2;3],1
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
testId, containerType, query, expectedOutput
2+
BS-010-Query-with-limit-001,GS_CONTAINER_COLLECTION,select * limit 1,0
3+
BS-010-Query-with-limit-002,GS_CONTAINER_COLLECTION,select * limit a,1
4+
BS-010-Query-with-limit-003,GS_CONTAINER_TIME_SERIES,select * limit 1,0
5+
BS-010-Query-with-limit-004,GS_CONTAINER_TIME_SERIES,select * limit a,1
6+
BS-010-Query-with-limit-005,GS_CONTAINER_COLLECTION,select * limit -1,1
7+
BS-010-Query-with-limit-006,GS_CONTAINER_TIME_SERIES,select * limit -1,1
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
testID,Stack index,Buffer size,Expected Output
2+
Test get_error_stack_size(),,,
3+
UC-014-Error_utility-001,NA,NA,0
4+
UC-014-Error_utility-002,NA,NA,0
5+
Test get_error_code(),,,
6+
UC-014-Error_utility-003,0,NA,A number different to 0
7+
UC-014-Error_utility-004,2147483647,NA,0
8+
UC-014-Error_utility-005,-1,NA,A number different to 0
9+
UC-014-Error_utility-006,-2147483649,NA,A number different to 0
10+
UC-014-Error_utility-007,2147483648,NA,0
11+
UC-014-Error_utility-008,1.1,NA,A number different to 0
12+
UC-014-Error_utility-009,a,NA,A number different to 0
13+
Test format_error_message(),,,
14+
UC-014-Error_utility-010,0,100,"Error message contains ""cluster name invalid"""
15+
UC-014-Error_utility-011,2147483647,30,Empty string
16+
UC-014-Error_utility-012,-1,30,Non-empty string
17+
UC-014-Error_utility-013,-2147483649,30,Non-empty string
18+
UC-014-Error_utility-014,2147483648,30,Empty string
19+
UC-014-Error_utility-015,1.1,30,Non-empty string
20+
UC-014-Error_utility-016,a,30,Non-empty string
21+
UC-014-Error_utility-018,0,-1,Non-empty string
22+
UC-014-Error_utility-019,0,-2147483649,Non-empty string
23+
UC-014-Error_utility-020,0,2147483648,Empty string
24+
UC-014-Error_utility-021,0,1.1,Empty string
25+
UC-014-Error_utility-022,0,a,Empty string
26+
Test format_error_location(),,,
27+
UC-014-Error_utility-023,0,100,Non-empty string
28+
UC-014-Error_utility-024,2147483647,30,Empty string
29+
UC-014-Error_utility-025,-1,30,Non-empty string
30+
UC-014-Error_utility-026,-2147483649,30,Non-empty string
31+
UC-014-Error_utility-027,2147483648,30,Empty string
32+
UC-014-Error_utility-028,1.1,30,Non-empty string
33+
UC-014-Error_utility-029,a,30,Non-empty string
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
testId,ContainerType, containerName, containerType, rowKeyAssigned, columnInfoList, expirationInfo, expectedOutput
2+
BS-015-ContainerInfo_set_get-001,GS_CONTAINER_COLLECTION,Abc_123,GS_CONTAINER_COLLECTION,True,[[A_0:GS_TYPE_STRING];[A9:GS_TYPE_BOOL];[za:GS_TYPE_DOUBLE]],[10;20;30],0
3+
BS-015-ContainerInfo_set_get-002,GS_CONTAINER_TIME_SERIES,Abc_123,GS_CONTAINER_TIME_SERIES,False,[[A_0:GS_TYPE_STRING];[A9:GS_TYPE_BOOL];[za:GS_TYPE_DOUBLE]],[10;20;30],0
4+
BS-015-ContainerInfo_set_get-003,GS_CONTAINER_COLLECTION,Abc_123,GS_CONTAINER_COLLECTION,1.1,[[A_0:GS_TYPE_STRING];[A9:GS_TYPE_BOOL];[za:GS_TYPE_DOUBLE]],[10;20;30],1
5+
BS-015-ContainerInfo_set_get-004,GS_CONTAINER_TIME_SERIES,Abc_123,GS_CONTAINER_TIME_SERIES,abc,[[A_0:GS_TYPE_STRING];[A9:GS_TYPE_BOOL];[za:GS_TYPE_DOUBLE]],[10;20;30],1
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
testId, containerType, rowExpirationTime, rowExpirationTimeUnit, expirationDivisionCount, expectedOutput
2+
BS-016-ExpirationInfo_set_get-001,string,1,0,10,0
3+
BS-016-ExpirationInfo_set_get-002,integer,9,10,10,0
4+
BS-016-ExpirationInfo_set_get-003,long,99,100,10,0
5+
BS-016-ExpirationInfo_set_get-004,timestamp,999,1000,10,0

0 commit comments

Comments
 (0)