Browse Source

print stdout in misc tests

Simon Krajewski 10 years ago
parent
commit
dd57aab5a1
1 changed files with 5 additions and 1 deletions
  1. 5 1
      tests/misc/src/Main.hx

+ 5 - 1
tests/misc/src/Main.hx

@@ -73,7 +73,7 @@ class Main {
 
 	static function runCommand(command:String, args:Array<String>, expectFailure:Bool, expectStderr:String) {
 		var proc = new sys.io.Process(command, args);
-		proc.stdout.readAll();
+		var stdout = proc.stdout.readAll();
 		var exit = proc.exitCode();
 		var success = exit == 0;
 		var result = switch [success, expectFailure] {
@@ -90,6 +90,10 @@ class Main {
 				false;
 		}
 
+		if (stdout.length > 0) {
+			Sys.println(stdout);
+		}
+
 		if (result && expectStderr != null)
 		{
 			var stderr = proc.stderr.readAll().toString().replace("\r\n", "\n").trim();