risdenk commented on a change in pull request #729:
URL: https://github.com/apache/solr/pull/729#discussion_r820845400



##########
File path: 
solr/modules/ltr/src/test/org/apache/solr/ltr/model/TestAdapterModel.java
##########
@@ -62,21 +62,22 @@ public void setup() throws Exception {
         "popularity", FieldValueFeature.class.getName(), "test", 
"{\"field\":\"popularity\"}");
 
     scoreValue = random().nextFloat();
-    final File scoreValueFile = new File(tmpConfDir, "scoreValue.txt");
+    final Path scoreValueFile = tmpConfDir.resolve("scoreValue.txt");
     try (BufferedWriter writer =
         new BufferedWriter(
-            new OutputStreamWriter(new FileOutputStream(scoreValueFile), 
StandardCharsets.UTF_8))) {
+            new OutputStreamWriter(
+                Files.newOutputStream(scoreValueFile), 
StandardCharsets.UTF_8))) {
       writer.write(Float.toString(scoreValue));
     }
-    scoreValueFile.deleteOnExit();
+    scoreValueFile.toFile().deleteOnExit();

Review comment:
       addressed in d1c7ce9




-- 
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: issues-unsubscr...@solr.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to