@Override
    public int launch(AgentLaunchDescriptor descriptor) {
        LogConfigurator logConfigurator = new LogConfigurator("agent-launcher-logback.xml");
        return logConfigurator.runWithLogger(() -> doLaunch(descriptor));
    }
@Test
    public void shouldDownloadLauncherJarIfLocalCopyIsStale_butShouldReturnWithoutDownloadingOrLaunchingAgent() throws Exception {
        File launcher = randomFile(AGENT_LAUNCHER_JAR);
        long original = launcher.length();
        File agentFile = randomFile(AGENT_BINARY_JAR);
        long originalAgentLength = agentFile.length();
        new AgentLauncherImpl().launch(launchDescriptor());

        assertThat(launcher.length(), not(original));
        assertThat(agentFile.length(), is(originalAgentLength));
    }