Myasuka commented on code in PR #21410:
URL: https://github.com/apache/flink/pull/21410#discussion_r1045708784


##########
flink-runtime/src/test/java/org/apache/flink/runtime/state/FileStateBackendMigrationTest.java:
##########
@@ -18,18 +18,24 @@
 package org.apache.flink.runtime.state;
 
 import org.apache.flink.runtime.state.filesystem.FsStateBackend;
+import org.apache.flink.testutils.junit.extensions.parameterized.Parameters;
 
-import java.io.File;
+import java.util.Arrays;
+import java.util.Collection;
 
 /**
  * Tests for the keyed state backend and operator state backend, as created by 
the {@link
  * FsStateBackend}.
  */
 public class FileStateBackendMigrationTest extends 
StateBackendMigrationTestBase<FsStateBackend> {
 
+    @Parameters
+    public static Collection<Object> modes() {
+        return Arrays.asList("just to please junit5 parameter test in base 
class");

Review Comment:
   I don't think this sentence could be understood well.



##########
flink-state-backends/flink-statebackend-changelog/src/main/java/org/apache/flink/state/changelog/ChangelogMapState.java:
##########
@@ -61,17 +62,7 @@
 
     private Map.Entry<UK, UV> loggingMapEntry(
             Map.Entry<UK, UV> entry, KvStateChangeLogger<Map<UK, UV>, N> 
changeLogger, N ns) {
-        return new Map.Entry<UK, UV>() {
-            @Override
-            public UK getKey() {
-                return entry.getKey();
-            }
-
-            @Override
-            public UV getValue() {
-                return entry.getValue();
-            }
-
+        return new AbstractMap.SimpleEntry<UK, UV>(entry.getKey(), 
entry.getValue()) {

Review Comment:
   I don't this change has relationship with junit5 refactor.



##########
flink-state-backends/flink-statebackend-rocksdb/src/test/java/org/apache/flink/contrib/streaming/state/EmbeddedRocksDBStateBackendTest.java:
##########
@@ -148,13 +145,16 @@ public static List<Object[]> modes() {
     private final RocksDBResourceContainer optionsContainer = new 
RocksDBResourceContainer();
 
     public void prepareRocksDB() throws Exception {
-        String dbPath = new File(TEMP_FOLDER.newFolder(), 
DB_INSTANCE_DIR_STRING).getAbsolutePath();
+        File dbPath = new File(tmpDbPath, DB_INSTANCE_DIR_STRING);
+        if (!dbPath.exists()) {
+            dbPath.mkdirs();

Review Comment:
   Why we need this after switching junit5?



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