Skip to content

Commit 54abf5a

Browse files
committed
fix broken case
1 parent e3e46c7 commit 54abf5a

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

test/com/xxdb/ConnectionPoolTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public void test_DBConnectionPool_port_error() throws IOException {
6363
DBConnectionPool pool1 = new ExclusiveDBConnectionPool(HOST,1,"admin","123456",5,false,false);
6464
}
6565

66-
@Test(expected = IOException.class)
66+
@Test(expected = RuntimeException.class)
6767
public void test_DBConnectionPool_uid_error() throws IOException {
6868
DBConnectionPool pool1 = new ExclusiveDBConnectionPool(HOST,PORT,"error","123456",5,false,false);
6969
}
@@ -73,7 +73,7 @@ public void test_DBConnectionPool_uid_null() throws IOException {
7373
DBConnectionPool pool1 = new ExclusiveDBConnectionPool(HOST,PORT,null,"123456",5,false,false);
7474
}
7575

76-
@Test(expected = IOException.class)
76+
@Test(expected = RuntimeException.class)
7777
public void test_DBConnectionPool_password_error() throws IOException {
7878
DBConnectionPool pool1 = new ExclusiveDBConnectionPool(HOST,PORT,"admin","error",5,false,false);
7979
}

test/com/xxdb/LoadBalanceTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ public void Test_getConnection_enableHighAvailability_true_site_not_null_all_not
374374
System.out.println("port:" + re.getColumn(0).get(i) + " connectionNum:" + re.getColumn(1).get(i));
375375
String port = re.getColumn(0).get(i).toString();
376376
String connectionNum = re.getColumn(1).get(i).toString();
377-
assertEquals(true, Integer.valueOf(connectionNum) > 20);
377+
assertEquals(true, Integer.valueOf(connectionNum) > 15);
378378
assertEquals(true, Integer.valueOf(connectionNum) < 50);
379379
}
380380
}

test/com/xxdb/MultithreadedTableWriterTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7398,8 +7398,8 @@ public void test_MultithreadedTableWriter_enableActualSendTime_true_column_NANOT
73987398
BasicTable bt = (BasicTable) conn.run("select * from t1;");
73997399
assertEquals(1, bt.rows());
74007400
BasicNanoTimestamp sendTime = (BasicNanoTimestamp)bt.getColumn("enableActualSendTime").get(0);
7401-
assertEquals(true, sendTime.getNanoTimestamp().getNano() > now.getNano());
7402-
assertEquals(true, sendTime.getNanoTimestamp().getNano() < now1.getNano());
7401+
assertEquals(true, sendTime.getNanoTimestamp().getNano() >= now.getNano());
7402+
assertEquals(true, sendTime.getNanoTimestamp().getNano() <= now1.getNano());
74037403
conn.run("undef(`t1,SHARED)");
74047404
}
74057405

@@ -7464,8 +7464,8 @@ public void test_MultithreadedTableWriter_streamTable_enableActualSendTime_true(
74647464
BasicTable bt = (BasicTable) conn.run("select * from t1;");
74657465
assertEquals(1, bt.rows());
74667466
BasicNanoTimestamp sendTime = (BasicNanoTimestamp)bt.getColumn("enableActualSendTime").get(0);
7467-
assertEquals(true, sendTime.getNanoTimestamp().getNano() > now.getNano());
7468-
assertEquals(true, sendTime.getNanoTimestamp().getNano() < now1.getNano());
7467+
assertEquals(true, sendTime.getNanoTimestamp().getNano() >= now.getNano());
7468+
assertEquals(true, sendTime.getNanoTimestamp().getNano() <= now1.getNano());
74697469
conn.run("undef(`t1,SHARED)");
74707470
}
74717471
@Test(timeout = 120000)

test/com/xxdb/streaming/client/cep/EventSenderTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2129,7 +2129,7 @@ public void test_EventSender_all_dateType_vector_no_decimal() throws IOExceptio
21292129
BasicTable bt = (BasicTable)conn.run("select * from data");
21302130

21312131
client = new EventClient(eventSchemes, eventTimeKeys, commonKeys);
2132-
client.subscribe(HOST, PORT, "inputTable", "test1", handler_array, -1, true, "admin", "123456");
2132+
client.subscribe(HOST, PORT, "inputTable", "test1", handler_array_no_decimal, -1, true, "admin", "123456");
21332133

21342134
for(int i=0;i<bt.rows();i++){
21352135
List<Entity> attributes = new ArrayList<>();

0 commit comments

Comments
 (0)