Skip to content

Commit

Permalink
1918310 - fix outgoingbatchservicetest that worked for mysql, but not…
Browse files Browse the repository at this point in the history
… for derby.
  • Loading branch information
chenson42 committed Mar 19, 2008
1 parent 7fa7532 commit 16c1439
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Expand Up @@ -223,7 +223,8 @@ public void testErrorChannel() {
Assert.assertEquals(batches.size(), 3);
String firstBatchId = batches.get(0).getBatchId();
String secondBatchId = batches.get(1).getBatchId();

String thirdBatchId = batches.get(2).getBatchId();

// Ack the first batch as an error, leaving the others as new
ArrayList<BatchInfo> ackList = new ArrayList<BatchInfo>();
ackList.add(new BatchInfo(firstBatchId, 1));
Expand All @@ -233,10 +234,13 @@ public void testErrorChannel() {
batches = batchService.getOutgoingBatches(TestConstants.TEST_CLIENT_EXTERNAL_ID);
Assert.assertNotNull(batches);
Assert.assertEquals(batches.size(), 3);
Assert.assertEquals(batches.get(0).getBatchId(), secondBatchId,
"Channel in error should have batches last - missing new batch");
Assert.assertEquals(batches.get(1).getBatchId(), firstBatchId,
"Channel in error should have batches last - missing error batch");
Assert.assertEquals(batches.get(2).getBatchId(), secondBatchId,
Assert.assertEquals(batches.get(2).getBatchId(), thirdBatchId,
"Channel in error should have batches last - missing new batch");

}

protected void createDataEvent(String tableName, int auditId, String channelId, DataEventType type,
Expand Down
2 changes: 1 addition & 1 deletion symmetric/src/test/resources/test-continuous-setup.sql
@@ -1,5 +1,5 @@
insert into sym_channel values('testchannel', 1, 50, 50, 1, null);
insert into sym_channel values('config', 1, 50, 50, 1, null);
insert into sym_channel values('config', 0, 50, 50, 1, null);
insert into sym_node_group values ('symmetric','a group representing symmetric configuration');
insert into sym_node_group values ('test-root-group','a test config');
insert into sym_node_group values ('test-node-group','a test config');
Expand Down

0 comments on commit 16c1439

Please sign in to comment.