tkalkirill commented on code in PR #1556:
URL: https://github.com/apache/ignite-3/pull/1556#discussion_r1083941400


##########
modules/table/src/test/java/org/apache/ignite/internal/table/distributed/raft/snapshot/outgoing/OutgoingSnapshotCommonTest.java:
##########
@@ -76,12 +64,13 @@ void returnsKeyFromStorage() {
 
     @Test
     void sendsSnapshotMeta() {
-        when(mvPartitionStorage.lastAppliedIndex()).thenReturn(100L);
-        lenient().when(mvPartitionStorage.lastAppliedTerm()).thenReturn(3L);
-        when(txStateStorage.lastAppliedIndex()).thenReturn(100L);
-        lenient().when(txStateStorage.lastAppliedTerm()).thenReturn(3L);
+        lenient().when(partitionAccess.minLastAppliedIndex()).thenReturn(90L);

Review Comment:
   Fix it



##########
modules/table/src/test/java/org/apache/ignite/internal/table/distributed/raft/snapshot/PartitionSnapshotStorageFactoryTest.java:
##########
@@ -44,24 +39,18 @@
  */
 @ExtendWith(MockitoExtension.class)
 public class PartitionSnapshotStorageFactoryTest {
-    private final MvPartitionStorage mvPartitionStorage = new 
TestMvPartitionStorage(0);
-    private final TxStateStorage txStateStorage = new TestTxStateStorage();
-
     @Mock
     private PartitionAccess partitionAccess;
 
-    @BeforeEach
-    void configureMocks() {
-        
when(partitionAccess.mvPartitionStorage()).thenReturn(mvPartitionStorage);
-        
when(partitionAccess.txStatePartitionStorage()).thenReturn(txStateStorage);
-    }
-
     @Test
     void testForChoosingMinimumAppliedIndexForMeta() {
-        mvPartitionStorage.lastApplied(10L, 2L);
-        txStateStorage.lastApplied(5L, 1L);
+        lenient().when(partitionAccess.minLastAppliedIndex()).thenReturn(5L);

Review Comment:
   Fix it



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