I implemented an abstract subtype of Job/Run that can be used to model external asynchronous execution. See [1,2].
While asynchronous process is ongoing, additional lines can be written to console. When it's done, you call the markCompleted() method to really end the build. The original driver for this effort was the Jenkow plugin, which wants to capture the execution of a workflow as a build, but I think it's an useful building block for other plugins. The plugin has an example of how to use these base types in its src/test/java. [1] https://wiki.jenkins-ci.org/display/JENKINS/Async+Job+Plugin [2] https://github.com/jenkinsci/async-job-plugin -- Kohsuke Kawaguchi
