DomGarguilo commented on code in PR #2863:
URL: https://github.com/apache/accumulo/pull/2863#discussion_r943747073
##########
test/src/main/java/org/apache/accumulo/test/ScanServerIT.java:
##########
@@ -132,46 +127,20 @@ public void testBatchScan() throws Exception {
try (AccumuloClient client =
Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
- client.tableOperations().create(tableName);
-
- ReadWriteIT.ingest(client, 10, 10, 50, 0, tableName);
-
- client.tableOperations().flush(tableName, null, null, true);
+ createTableAndIngest(client, tableName);
try (BatchScanner scanner = client.createBatchScanner(tableName,
Authorizations.EMPTY)) {
scanner.setRanges(Collections.singletonList(new Range()));
scanner.setConsistencyLevel(ConsistencyLevel.EVENTUAL);
- assertEquals(100, Iterables.size(scanner));
+ assertEquals(EXPECTED_INGEST_ENTRIES_COUNT, Iterables.size(scanner));
ReadWriteIT.ingest(client, 10, 10, 50, 10, tableName);
- assertEquals(100, Iterables.size(scanner));
+ assertEquals(EXPECTED_INGEST_ENTRIES_COUNT, Iterables.size(scanner));
scanner.setConsistencyLevel(ConsistencyLevel.IMMEDIATE);
- assertEquals(200, Iterables.size(scanner));
+ assertEquals(EXPECTED_INGEST_ENTRIES_COUNT * 2,
Iterables.size(scanner));
} // when the scanner is closed, all open sessions should be closed
}
}
- @Test
- public void testScanOfflineTable() throws Exception {
Review Comment:
Addressed in cfa97a1
##########
test/src/main/java/org/apache/accumulo/test/ScanServerIT_NoServers.java:
##########
@@ -106,43 +102,17 @@ public void testBatchScan() throws Exception {
try (AccumuloClient client =
Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
- client.tableOperations().create(tableName);
-
- ReadWriteIT.ingest(client, 10, 10, 50, 0, tableName);
-
- client.tableOperations().flush(tableName, null, null, true);
+ createTableAndIngest(client, tableName);
try (BatchScanner scanner = client.createBatchScanner(tableName,
Authorizations.EMPTY)) {
scanner.setRanges(Collections.singletonList(new Range()));
scanner.setConsistencyLevel(ConsistencyLevel.EVENTUAL);
- assertEquals(100, Iterables.size(scanner));
+ assertEquals(EXPECTED_INGEST_ENTRIES_COUNT, Iterables.size(scanner));
ReadWriteIT.ingest(client, 10, 10, 50, 10, tableName);
- // since there are no scan servers and we are reading from tservers we
should see update
- assertEquals(200, Iterables.size(scanner));
+ // since there are no scan servers, and we are reading from tservers,
we should see update
+ assertEquals(EXPECTED_INGEST_ENTRIES_COUNT * 2,
Iterables.size(scanner));
} // when the scanner is closed, all open sessions should be closed
}
}
- @Test
- public void testScanOfflineTable() throws Exception {
Review Comment:
Addressed in cfa97a1
--
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]