rkhachatryan commented on a change in pull request #18729:
URL: https://github.com/apache/flink/pull/18729#discussion_r805595444



##########
File path: 
flink-tests/src/test/java/org/apache/flink/test/checkpointing/SavepointFormatITCase.java
##########
@@ -78,138 +82,151 @@
     LoggerAuditingExtension loggerAuditingExtension =
             new LoggerAuditingExtension(SavepointFormatITCase.class, 
Level.INFO);
 
-    private static Stream<Arguments> parameters() {
-        return Stream.of(
-                Arguments.of(
-                        SavepointFormatType.CANONICAL,
-                        HEAP,
-                        (Consumer<KeyedStateHandle>)
-                                keyedState ->
-                                        assertThat(
-                                                keyedState,
-                                                
instanceOf(SavepointKeyedStateHandle.class))),
-                Arguments.of(
-                        SavepointFormatType.NATIVE,
-                        HEAP,
-                        (Consumer<KeyedStateHandle>)
-                                keyedState ->
-                                        assertThat(
-                                                keyedState,
-                                                
instanceOf(KeyGroupsStateHandle.class))),
-                Arguments.of(
-                        SavepointFormatType.CANONICAL,
-                        ROCKSDB_FULL_SNAPSHOTS,
-                        (Consumer<KeyedStateHandle>)
-                                keyedState ->
-                                        assertThat(
-                                                keyedState,
-                                                
instanceOf(SavepointKeyedStateHandle.class))),
-                Arguments.of(
-                        SavepointFormatType.NATIVE,
-                        ROCKSDB_FULL_SNAPSHOTS,
-                        (Consumer<KeyedStateHandle>)
-                                keyedState ->
-                                        assertThat(
-                                                keyedState,
-                                                
instanceOf(KeyGroupsStateHandle.class))),
-                Arguments.of(
-                        SavepointFormatType.CANONICAL,
-                        ROCKSDB_INCREMENTAL_SNAPSHOTS,
-                        (Consumer<KeyedStateHandle>)
-                                keyedState ->
-                                        assertThat(
-                                                keyedState,
-                                                
instanceOf(SavepointKeyedStateHandle.class))),
-                Arguments.of(
-                        SavepointFormatType.NATIVE,
-                        ROCKSDB_INCREMENTAL_SNAPSHOTS,
-                        (Consumer<KeyedStateHandle>)
-                                keyedState ->
-                                        assertThat(
-                                                keyedState,
-                                                instanceOf(
-                                                        
IncrementalRemoteKeyedStateHandle.class))));
+    private static List<Arguments> parameters() {

Review comment:
       I agree that the assertions are now disconnected from the inputs.
   But looking at it from a different perspective, this allows to understand 
what the end result should be via `validateState`; for example, `CANONICAL` 
savepoints always result in  `SavepointKeyedStateHandle`.
   
   So I'd leave it with the loops.




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