@Override
    public Integer call() throws Exception {
        return this.call(
            Flow.class,
            yamlFlowParser,
            modelValidator,
            (Object object) -> {
                Flow flow = (Flow) object;
                return flow.getNamespace() + " / " + flow.getId();
            },
            (Object object) -> {
                Flow flow = (Flow) object;
                List<String> warnings = new ArrayList<>();
                warnings.addAll(flowService.deprecationPaths(flow).stream().map(deprecation -> deprecation + " is deprecated").toList());
                warnings.addAll(flowService.relocations(flow.generateSource()).stream().map(relocation -> relocation.from() + " is replaced by " + relocation.to()).toList());
                warnings.addAll(flowService.warnings(flow));
                return warnings;
            }
        );
    }
@Test
    void run() {
        ByteArrayOutputStream out = new ByteArrayOutputStream();
        System.setOut(new PrintStream(out));

        try (ApplicationContext ctx = ApplicationContext.builder().deduceEnvironment(false).start()) {
            String[] args = {
                "--local",
                "src/test/resources/helper/flow.yaml"
            };
            Integer call = PicocliRunner.call(FlowValidateCommand.class, ctx, args);

            assertThat(call, is(0));
            assertThat(out.toString(), containsString("✓ - io.kestra.cli / include"));
        }
    }