steveloughran commented on a change in pull request #1404: HDFS-13660 Copy file 
till the source file length during distcp
URL: https://github.com/apache/hadoop/pull/1404#discussion_r322700169
 
 

 ##########
 File path: 
hadoop-tools/hadoop-distcp/src/test/java/org/apache/hadoop/tools/util/TestDistCpUtils.java
 ##########
 @@ -1224,17 +1224,20 @@ public void testCompareFileLengthsAndChecksums() 
throws IOException {
     Path dstWithLen0 = new Path(base + "dstLen0");
     fs.create(srcWithLen0).close();
     fs.create(dstWithLen0).close();
-    DistCpUtils.compareFileLengthsAndChecksums(fs, srcWithLen0,
-        null, fs, dstWithLen0, false);
+    CopyListingFileStatus src = new CopyListingFileStatus(
+            0L, false, 2, 512 << 20, 1234L, 5678L, new 
FsPermission((short)0512),
+            "dingo", "yaks", new Path("hdfs://localhost:4344"));
+    DistCpUtils.compareFileLengthsAndChecksums(0, fs, srcWithLen0,
+        null, fs, dstWithLen0, false, 0);
 
     // different lengths comparison
     Path srcWithLen1 = new Path(base + "srcLen1");
     Path dstWithLen2 = new Path(base + "dstLen2");
     DFSTestUtil.createFile(fs, srcWithLen1, 1, replFactor, srcSeed);
     DFSTestUtil.createFile(fs, dstWithLen2, 2, replFactor, srcSeed);
     try {
 
 Review comment:
   you can move to intercept() here too

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to