public static void checkResult(KeyedTable keyedTable, int exceptedSize) {
    keyedTable.refresh();
    Snapshot crt = keyedTable.changeTable().currentSnapshot();

    Stack<Snapshot> snapshots = new Stack<>();
    while (crt != null) {
      snapshots.push(crt);
      if (crt.parentId() == null) {
        break;
      }
      crt = keyedTable.changeTable().snapshot(crt.parentId());
    }

    Set<String> paths = new HashSet<>();
    long maxTxId = -1;
    while (!snapshots.isEmpty()) {
      Snapshot snapshot = snapshots.pop();
      long minTxIdInSnapshot = Integer.MAX_VALUE;
      long maxTxIdInSnapshot = -1;
      for (DataFile addedFile : snapshot.addedDataFiles(keyedTable.io())) {
        String path = addedFile.path().toString();
        Assert.assertFalse(paths.contains(path));
        paths.add(path);
        LOG.info("add file: {}", addedFile.path());

        long txId = FileNameRules.parseChange(path, snapshot.sequenceNumber()).transactionId();
        minTxIdInSnapshot = Math.min(minTxIdInSnapshot, txId);
        maxTxIdInSnapshot = Math.max(maxTxIdInSnapshot, txId);
      }
      Assert.assertTrue(maxTxId <= minTxIdInSnapshot);

      maxTxId = maxTxIdInSnapshot;
    }

    Assert.assertEquals(exceptedSize, TestMixedFormatSource.tableRecords(keyedTable).size());
  }
Whether the test is executing in a scenario that induces a failover. This doesn't mean that
this source induces the failover.
amoro-format-mixed/amoro-mixed-flink/amoro-mixed-flink-common/src/test/java/org/apache/amoro/flink/write/MixedFormatFileWriterITCase.java