flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zentol <...@git.apache.org>
Subject [GitHub] flink pull request #6399: [FLINK-5860] [tests] Replace java.io.tmpdir with J...
Date Tue, 24 Jul 2018 11:49:46 GMT
Github user zentol commented on a diff in the pull request:

    https://github.com/apache/flink/pull/6399#discussion_r204720065
  
    --- Diff: flink-core/src/test/java/org/apache/flink/api/common/io/EnumerateNestedFilesTest.java
---
    @@ -338,22 +279,11 @@ public void testGetStatisticsMultipleNestedFiles() {
     			String secondLevelDir = TestFileUtils.randomFileName();
     			String secondLevelDir2 = TestFileUtils.randomFileName();
     
    -			File nestedDir = new File(tempPath + System.getProperty("file.separator") 
    -					+ firstLevelDir);
    -			nestedDir.mkdirs();
    -			nestedDir.deleteOnExit();
    +			File insideNestedDir = tempFolder.newFolder(firstLevelDir, secondLevelDir);
    +			File insideNestedDir2 = tempFolder.newFolder(firstLevelDir, secondLevelDir2);
    +			File nestedDir = insideNestedDir.getParentFile();
     
    -			File insideNestedDir = new File(tempPath + System.getProperty("file.separator") 
    -					+ firstLevelDir + System.getProperty("file.separator") + secondLevelDir);
    -			insideNestedDir.mkdirs();
    -			insideNestedDir.deleteOnExit();
    -
    -			File insideNestedDir2 = new File(tempPath + System.getProperty("file.separator")
    -					+ firstLevelDir + System.getProperty("file.separator") + secondLevelDir2);
    -			insideNestedDir2.mkdirs();
    -			insideNestedDir2.deleteOnExit();
    -
    -			// create a file in the first-level and two files in the nested dir
    +				// create a file in the first-level and two files in the nested dir
    --- End diff --
    
    revert indentation change


---

Mime
View raw message