zhoulii commented on code in PR #20168:
URL: https://github.com/apache/flink/pull/20168#discussion_r998861965


##########
flink-table/flink-sql-client/src/test/java/org/apache/flink/table/client/cli/CliClientITCase.java:
##########
@@ -124,45 +136,52 @@ public static void setup() throws IOException {
 
         File udfJar =
                 UserClassLoaderJarTestUtils.createJarFile(
-                        tempFolder.newFolder("test-jar"),
+                        Files.createTempDirectory(tempFolder, 
"test-jar").toFile(),
                         "test-classloader-udf.jar",
                         classNameCodes);
         URL udfDependency = udfJar.toURI().toURL();
         String path = udfDependency.getPath();
         // we need to pad the displayed "jars" tableau to have the same width 
of path string
         // 4 for the "jars" characters, see `set.q` test file
         int paddingLen = path.length() - 4;
-        historyPath = tempFolder.newFile("history").toPath();
+        historyPath = Files.createTempFile(tempFolder, "history", "");
 
         replaceVars = new HashMap<>();
         replaceVars.put("$VAR_UDF_JAR_PATH", path);
         replaceVars.put("$VAR_UDF_JAR_PATH_DASH", repeat('-', paddingLen));
         replaceVars.put("$VAR_UDF_JAR_PATH_SPACE", repeat(' ', paddingLen));
         replaceVars.put("$VAR_PIPELINE_JARS_URL", udfDependency.toString());
-        replaceVars.put(
-                "$VAR_REST_PORT",
-                
MINI_CLUSTER_RESOURCE.getClientConfiguration().get(PORT).toString());
-        replaceVars.put(
-                "$VAR_JOBMANAGER_RPC_ADDRESS",
-                MINI_CLUSTER_RESOURCE.getClientConfiguration().get(ADDRESS));
+        replaceVars.put("$VAR_REST_PORT", configuration.get(PORT).toString());
+        replaceVars.put("$VAR_JOBMANAGER_RPC_ADDRESS", 
configuration.get(ADDRESS));
     }
 
-    @Before
+    @BeforeEach
     public void before() throws IOException {

Review Comment:
   done



-- 
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]

Reply via email to