sodonnel commented on a change in pull request #2653:
URL: https://github.com/apache/ozone/pull/2653#discussion_r712469303
##########
File path:
hadoop-ozone/client/src/test/java/org/apache/hadoop/ozone/client/TestOzoneECClient.java
##########
@@ -184,29 +184,12 @@ public void testPutECKeyAndReadContent() throws
IOException {
Assert.assertEquals(keyName, key.getName());
try (OzoneInputStream is = bucket.readKey(keyName)) {
byte[] fileContent = new byte[1024];
- Assert.assertEquals(inputChunks[0].length, is.read(fileContent));
- Assert.assertEquals(new String(inputChunks[0], UTF_8),
- new String(fileContent, UTF_8));
- }
-
- // Since EC read is not ready yet, let's use the regular read by
- // tweaking the pipeline.
- // Remove first node in EC pipeline. So, regular read will hit the
- // first node in pipeline and assert for second chunk in EC data.
- updatePipelineToKeepSingleNode(2);
- try (OzoneInputStream is = bucket.readKey(keyName)) {
- byte[] fileContent = new byte[1024];
- Assert.assertEquals(inputChunks[1].length, is.read(fileContent));
- Assert.assertEquals(new String(inputChunks[1], UTF_8),
- new String(fileContent, UTF_8));
- }
-
- updatePipelineToKeepSingleNode(3);
- try (OzoneInputStream is = bucket.readKey(keyName)) {
- byte[] fileContent = new byte[1024];
- Assert.assertEquals(inputChunks[2].length, is.read(fileContent));
- Assert.assertEquals(new String(inputChunks[2], UTF_8),
- new String(fileContent, UTF_8));
+ for (int i=0; i<3; i++) {
Review comment:
Good point. I have fixed this.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]