8206241: compiler/graalunit/PhasesCommonTest.java fails with java.lang.Error: TESTBUG: no tests found for prefix org.graalvm.compiler.phases.common.test
Reviewed-by: kvn
--- a/test/hotspot/jtreg/compiler/graalunit/common/GraalUnitTestLauncher.java Fri Jul 20 11:39:37 2018 -0700
+++ b/test/hotspot/jtreg/compiler/graalunit/common/GraalUnitTestLauncher.java Fri Jul 20 11:39:52 2018 -0700
@@ -124,9 +124,12 @@
throw new Exception("Failed to find tests, VM crashed with exit code " + exitCode);
}
- System.out.println("INFO: command output: [" + out.getOutput() + "]");
+ String outStr = out.getOutput().trim();
+ System.out.println("INFO: command output: [" + outStr + "]");
- String[] lines = out.getStdout().split(" ");
+ String[] lines = outStr.split(" ");
+ Arrays.sort(lines);
+
if (lines.length > 1) { // first line contains jar file name
for (int i = 1; i < lines.length; i++) {
String className = lines[i];