public void start() {
        LOG.info("Running process from " + executable.toAbsolutePath());

        CommandLine cmdLine = new CommandLine(executable.toAbsolutePath().toString());
        arguments.forEach(it -> cmdLine.addArgument(it, true));

        try {
            createExecutor().execute(cmdLine, environment.getEnv(), listener);
            listener.onStart();
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
@Test
    void testExitCode() throws ExecutionException, InterruptedException, TimeoutException {
        final CompletableFuture<Integer> exitCodeFuture = new CompletableFuture<>();

        final ProcessListener listener = new ProcessListener() {
            @Override
            public void onStart() {
            }

            @Override
            public void onStdOut(String line) {
                LOG.info("Stdout:" + line);
            }

            @Override
            public void onStdErr(String line) {
                LOG.info("Stderr:" + line);
            }

            @Override
            public void onProcessComplete(int exitValue) {
                exitCodeFuture.complete(exitValue);
            }

            @Override
            public void onProcessFailed(ExecuteException e) {
                exitCodeFuture.complete(e.getExitValue());
            }
        };
        final CommandLineProcess process = new CommandLineProcess(binPath, List.of("143"), listener, new Environment(System.getenv()));
        process.start();

        final Integer exitCode = exitCodeFuture.get(10, TimeUnit.SECONDS);

        Assertions.assertThat(exitCode).isEqualTo(143);
    }