public static CheckResult mergeCheckResults(CheckResult... checkResults) {
        List<CheckResult> notPassConfig =
                Arrays.stream(checkResults)
                        .filter(item -> !item.isSuccess())
                        .collect(Collectors.toList());
        if (notPassConfig.isEmpty()) {
            return CheckResult.success();
        } else {
            String errMessage =
                    notPassConfig.stream()
                            .map(CheckResult::getMsg)
                            .collect(Collectors.joining(","));
            return CheckResult.error(errMessage);
        }
    }
@Test
    public void testMergeCheckResults() {
        Config config = getConfig();
        CheckResult checkResult1 = checkAllExists(config, "k0", "k1");
        CheckResult checkResult2 = checkAtLeastOneExists(config, "k1", "k3");
        CheckResult checkResult3 = checkAllExists(config, "k0", "k3");
        CheckResult checkResult4 = checkAtLeastOneExists(config, "k2", "k3");

        CheckResult finalResult = mergeCheckResults(checkResult1, checkResult2);
        Assertions.assertTrue(finalResult.isSuccess());

        String errorMsg1 = "please specify [%s] as non-empty";
        String errorMsg2 = "please specify at least one config of [%s] as non-empty";
        finalResult = mergeCheckResults(checkResult3, checkResult2);
        Assertions.assertEquals(String.format(errorMsg1, "k3"), finalResult.getMsg());

        finalResult = mergeCheckResults(checkResult3, checkResult4);
        Assertions.assertEquals(
                String.format(errorMsg1 + "," + errorMsg2, "k3", "k2,k3"), finalResult.getMsg());
    }