umustafi commented on code in PR #3864:
URL: https://github.com/apache/gobblin/pull/3864#discussion_r1468170534


##########
gobblin-service/src/test/java/org/apache/gobblin/service/GobblinServiceManagerTest.java:
##########
@@ -603,43 +683,41 @@ public void testGetAllPaginated() throws Exception {
         .setProperties(new StringMap(flowProperties));
     this.flowConfigClient.createFlowConfig(flowConfig4);
 
-    // Check that there are a total of 4 flowConfigs by using the default 
getAll call
+    // Check that the size of flowConfigs has increased by 4 using the default 
getAll call
     Collection<FlowConfig> flowConfigs = 
this.flowConfigClient.getAllFlowConfigs();
-    Assert.assertEquals(flowConfigs.size(), 4);
+    Assert.assertEquals(flowConfigs.size(), sizeBefore + 4);
 
-    // Check that there are a total of 4 flowConfigs using new getAll call
+    // Check that the size of flowConfigs has increased by 4 using new getAll 
call
     flowConfigs = this.flowConfigClient.getAllFlowConfigs(0,20);
-    Assert.assertEquals(flowConfigs.size(), 4);
+    Assert.assertEquals(flowConfigs.size(), sizeBefore + 4);
 
     // Attempt pagination with one element from the start of the specStore 
configurations stored
     // Start at index 0 and return 1 element
-    flowConfigs = this.flowConfigClient.getAllFlowConfigs(0,1);
+    flowConfigs = this.flowConfigClient.getAllFlowConfigs(sizeBefore,1);
     Assert.assertEquals(flowConfigs.size(), 1);
-    
Assert.assertEquals(((FlowConfig)(flowConfigs.toArray()[0])).getId().getFlowName(),
 "testFlow");
+    // TODO: remove these assertions which are flaky because the flows above 
all show up with the same modification time
+//    
Assert.assertEquals(((FlowConfig)(flowConfigs.toArray()[0])).getId().getFlowName(),
 TEST_FLOW_ID.getFlowName());

Review Comment:
   That's done in the latter part of this test where we iterate through the 
flow names and ensure the 3 new names are present



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to