Skip to content

Commit

Permalink
Revert "Launch Marathon sub-processes without test-classes"
Browse files Browse the repository at this point in the history
This reverts commit 458c175.
  • Loading branch information
Tim Harper committed Jan 31, 2017
1 parent 458c175 commit 3babb4f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,11 @@ case class RichRuntime(runtime: Runtime) extends StrictLogging {
val promise = Promise[Done]()
timer.schedule(new TimerTask {
override def run(): Unit = {
logger.info("Halting JVM")
promise.success(Done)
// do nothing in tests: we can't guarantee we can block the exit
if (!sys.props.get("java.class.path").exists(_.contains("test-classes"))) {
logger.info("Halting JVM")
Runtime.getRuntime.halt(exitCode)
} else {
logger.info("Cowardly refusing to halt the JVM while running tests")
}
}
}, waitForExit.toMillis)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -297,11 +297,7 @@ trait MarathonTest extends Suite with StrictLogging with ScalaFutures with Befor

val appProxyMainInvocationImpl: String = {
val javaExecutable = sys.props.get("java.home").fold("java")(_ + "/bin/java")
val classPath = sys.props.getOrElse("java.class.path", "target/classes").
replaceAll(" ", "").
split(":").
filterNot(_.contains("test-classes")).
mkString(":")
val classPath = sys.props.getOrElse("java.class.path", "target/classes").replaceAll(" ", "")
val main = classOf[AppMock].getName
val id = UUID.randomUUID.toString
appProxyIds(_ += id)
Expand Down

0 comments on commit 3babb4f

Please sign in to comment.