nizhikov commented on code in PR #11986:
URL: https://github.com/apache/ignite/pull/11986#discussion_r2044055948


##########
modules/compatibility/src/test/java/org/apache/ignite/compatibility/persistence/SnapshotCompatibilityTest.java:
##########
@@ -83,52 +82,50 @@ public class SnapshotCompatibilityTest extends 
IgniteCompatibilityAbstractTest {
     private static final String CUSTOM_SNP_RELATIVE_PATH = "ex_snapshots";
 
     /** */
-    private static final String CONSISTENT_ID = UUID.randomUUID().toString();
-
-    /** */
-    @Parameterized.Parameter
+    @Parameter
     public boolean incSnp;
 
     /** */
-    @Parameterized.Parameter(1)
-    @Nullable public String consId;
+    @Parameter(1)
+    public boolean customConsId;
 
     /** */
-    @Parameterized.Parameter(2)
+    @Parameter(2)
     public int oldNodesCnt;
 
     /** */
-    @Parameterized.Parameter(3)
+    @Parameter(3)
     public boolean cacheDump;
 
     /** */
-    @Parameterized.Parameter(4)
+    @Parameter(4)
     public boolean customSnpPath;
 
     /** */
-    @Parameterized.Parameter(5)
+    @Parameter(5)
     public boolean testCacheGrp;
 
     /** */
     private CacheGroupInfo cacheGrpInfo;
 
     /**
-     * The test is parameterized by whether an incremental snapshot is taken 
and by consistentId.
-     * Restore incremental snapshot if consistentId is null is fixed in 
2.17.0, see here https://issues.apache.org/jira/browse/IGNITE-23222.
-     * Also restoring cache dump and any kind of snapshot is pointless.
+     * Restore incremental snapshot if consistent ID is null is fixed in 
2.17.0, see here
+     * <a href="https://issues.apache.org/jira/browse/IGNITE-23222";>...</a>. 
Restore of an incremental snapshot doesn't work for different
+     * topology. Also restoring cache dump and any kind of snapshot is 
pointless.
      */
-    @Parameters(name = "incrementalSnp={0}, consistentID={1}, oldNodesCnt={2}, 
cacheDump={3}, customSnpPath={4}, testCacheGrp={5}")
+    @Parameters(name = "incSnp={0}, customConsId={1}, oldNodesCnt={2}, 
cacheDump={3}, customSnpPath={4}, testCacheGrp={5}")
     public static Collection<Object[]> data() {
         List<Object[]> data = new ArrayList<>();
 
         for (boolean incSnp : Arrays.asList(true, false))
-            for (String consId : Arrays.asList(CONSISTENT_ID, null))
+            for (boolean customConsId: Arrays.asList(true, false))
                 for (int oldNodesCnt : Arrays.asList(1, 3))
                     for (boolean cacheDump : Arrays.asList(true, false))
                         for (boolean customSnpPath : Arrays.asList(true, 
false))
                             for (boolean testCacheGrp : Arrays.asList(true, 
false))
-                                if ((!incSnp || !cacheDump) && (!incSnp || 
consId != null))
-                                    data.add(new Object[]{incSnp, consId, 
oldNodesCnt, cacheDump, customSnpPath, testCacheGrp});
+                                // see <a 
href="https://issues.apache.org/jira/browse/IGNITE-25096";>...</a>
+                                if (!incSnp || (!cacheDump && customConsId && 
oldNodesCnt == 1))

Review Comment:
   This clause looks very complicated.
   Let's:
   1. Simplify it. What cases do you want to skip?
   2. Mute those cases in test with the `assumeFalse` like:
   
   ```
       @Test
       public void testSnapshotRestore() throws Exception {
            assumeFalse("Description here", ...);
   
   ```



-- 
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: notifications-unsubscr...@ignite.apache.org

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

Reply via email to