Skip to content

Commit 5164b50

Browse files
committed
AJ-422:update test case
1 parent 0022abc commit 5164b50

File tree

4 files changed

+16
-7
lines changed

4 files changed

+16
-7
lines changed

test/com/xxdb/MultithreadedTableWriterTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1365,7 +1365,7 @@ public void test_insert_byte() throws Exception {
13651365
conn.run("undef(`t1,SHARED)");
13661366
}
13671367

1368-
@Test(timeout = 120000)
1368+
@Test(timeout = 60000)
13691369
public void test_insert_short() throws Exception {
13701370

13711371
StringBuilder sb = new StringBuilder();
@@ -1936,7 +1936,7 @@ public void test_insert_arrayVector_int()throws Exception {
19361936
conn.run("undef(`t1,SHARED)");
19371937
}
19381938

1939-
@Test(timeout = 120000)
1939+
@Test(timeout = 60000)
19401940
public void test_insert_arrayVector_char()throws Exception {
19411941

19421942
StringBuilder sb = new StringBuilder();

test/com/xxdb/data/BasicDecimal128Test.java

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,16 @@ public void testBasicDecimal128_scale_37() throws Exception {
110110
BasicDecimal128 Decimal1284 = new BasicDecimal128("0",37);
111111
assertEquals("0.0000000000000000000000000000000000000",Decimal1284.getString());
112112
}
113-
113+
@Test
114+
public void testBasicDecimal128_scale_39() throws Exception {
115+
String ex = null;
116+
try{
117+
BasicDecimal128 Decimal128 = new BasicDecimal128("9.9999999999999999999999999999999999999",39);
118+
}catch(Exception E){
119+
ex=E.getMessage();
120+
}
121+
assertEquals("Scale 39 is out of bounds, it must be in [0,38].",ex);
122+
}
114123
@Test
115124
public void testBasicDecimal128_getString1() {
116125
BasicDecimal128 Decimal128_a = new BasicDecimal128("103", 6);

test/com/xxdb/data/BasicDecimal128VectorTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ public void test_BasicDecimal128Vector_set_string() throws Exception {
145145
}catch(Exception E){
146146
ex=E.getMessage();
147147
}
148-
assertEquals("value type is not BasicDecimal128!",ex);
148+
assertEquals("The value type is not BasicDecimal128!",ex);
149149
}
150150
@Test
151151
public void test_BasicDecimal128Vector_new() throws Exception {
@@ -193,7 +193,7 @@ public void test_BasicDecimal128Vector_set_int() throws Exception {
193193
}catch(Exception E){
194194
RE = E.getMessage();
195195
}
196-
assertEquals("value type is not BasicDecimal128!",RE);
196+
assertEquals("The value type is not BasicDecimal128!",RE);
197197
}
198198

199199
@Test

test/com/xxdb/data/BasicDecimal32Test.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ public void testBasicDecimal32_value_string_scale_negative(){
7171
}catch(Exception E){
7272
ex=E.getMessage();
7373
}
74-
assertEquals("Scale out of bound (valid range: [0, 9], but get: -1)",ex);
74+
assertEquals("Scale -1 is out of bounds, it must be in [0,9].",ex);
7575
}
7676
@Test
7777
public void testBasicDecimal32_value_string_scale_0(){
@@ -122,7 +122,7 @@ public void testBasicDecimal32_value_string_scale_10(){
122122
}catch(Exception E){
123123
ex=E.getMessage();
124124
}
125-
assertEquals("Scale out of bound (valid range: [0, 9], but get: 10)",ex);
125+
assertEquals("Scale 10 is out of bounds, it must be in [0,9].",ex);
126126
}
127127

128128
@Test

0 commit comments

Comments
 (0)