You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@storm.apache.org by GitBox <gi...@apache.org> on 2019/09/09 16:16:07 UTC

[GitHub] [storm] srdo commented on a change in pull request #3126: STORM-3504: changed AsyncLocalizerTest to not mock AdvancedFSOps

srdo commented on a change in pull request #3126: STORM-3504: changed AsyncLocalizerTest to not mock AdvancedFSOps
URL: https://github.com/apache/storm/pull/3126#discussion_r322329586
 
 

 ##########
 File path: storm-server/src/test/java/org/apache/storm/localizer/AsyncLocalizerTest.java
 ##########
 @@ -94,7 +93,8 @@
     private ClientBlobStore mockblobstore = mock(ClientBlobStore.class);
 
     private static String getTestLocalizerRoot() {
-        File f = new File("./target/" + Thread.currentThread().getStackTrace()[2].getMethodName() + "/localizer/");
+        File f = new File("./target/" + Thread.currentThread().getStackTrace()[2].getMethodName() + "/localizer/")
+                .getAbsoluteFile();
         f.deleteOnExit();
 
 Review comment:
   I think we should use TmpPath instead of deleteOnExit to clean up test files, as they then get deleted when the test is done rather than when the JVM shuts down. Here's an example https://github.com/apache/storm/blob/23cd491da1ddc3cb684eb0a196101af5af64f6a9/storm-server/src/test/java/org/apache/storm/LocalStateTest.java#L31

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services