@Test
    public void testMismatchedWhenRestart() {
        final Pair<String, String> groupStream = saveSource("group1,group3");
        bindGroup(true, "group1");

        agent.pullTask();
        agent.pullTask(); // report last success status

        // suspend and restart
        suspendSource(groupStream.getLeft(), groupStream.getRight());
        restartSource(groupStream.getLeft(), groupStream.getRight());
        bindGroup(false, "group1");
        TaskResult taskResult = agent.pullTask();
        Assertions.assertEquals(1, taskResult.getDataConfigs().size());
        Assertions.assertEquals(1, taskResult.getDataConfigs().stream()
                .filter(dataConfig -> Integer.valueOf(dataConfig.getOp()) == ManagerOpEnum.FROZEN.getType())
                .collect(Collectors.toSet())
                .size());
    }
Test node group mismatch source task but group restart
inlong-manager/manager-service/src/test/java/org/apache/inlong/manager/service/core/impl/AgentServiceTest.java