Skip to content

Commit

Permalink
Added -timeout N option to change the server timeout for long runni…
Browse files Browse the repository at this point in the history
…ng CI tests
  • Loading branch information
elsassph committed Sep 23, 2015
1 parent 6974643 commit bfa00eb
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
Binary file modified src/run.n
Binary file not shown.
7 changes: 4 additions & 3 deletions tool/src/massive/munit/command/RunCommand.hx
Expand Up @@ -96,9 +96,6 @@ class RunCommand extends MUnitTargetCommandBase
{
super();
killBrowser = false;

// TODO: Configure this through args to munit for CI. ms 4/8/11
serverTimeoutTimeSec = DEFAULT_SERVER_TIMEOUT_SEC;
}

override public function initialise():Void
Expand Down Expand Up @@ -378,6 +375,10 @@ class RunCommand extends MUnitTargetCommandBase
tmpRunnerDir = tmpDir.resolveDirectory("runner");
reportRunnerDir.copyTo(tmpRunnerDir);

var userTimeout = console.getOption("timeout");
if (userTimeout != null) serverTimeoutTimeSec = Std.parseInt(userTimeout);
if (serverTimeoutTimeSec == null) serverTimeoutTimeSec = DEFAULT_SERVER_TIMEOUT_SEC;
else print('Running tests with $serverTimeoutTimeSec seconds timeout');

var serverProcess:Process = null;

Expand Down
3 changes: 3 additions & 0 deletions tool/template/help_run.txt
Expand Up @@ -26,3 +26,6 @@ Optional Parameters:
Works in Chrome but not other browsers due to JS security.

-result-exit-code : Exits with error code (1) if tests fail

-timeout : Maximum time that the tests are allowed to run (default: 30s)

0 comments on commit bfa00eb

Please sign in to comment.