changeset 12692:75549135a21f

8176471: [TESTBUG] runtime/modules/IgnoreModulePropertiesTest.java fails with OpenJDK: java.lang.RuntimeException: 'java version ' missing from stdout/stderr Summary: Check for strings such as " version " and "Runtime Environment" that appear in 'java -version' for both open and closed builds. Reviewed-by: coleenp
author hseigel
date Mon, 13 Mar 2017 16:23:17 -0400
parents 6868eb69ce70
children eef6e15f993a
files test/runtime/modules/IgnoreModulePropertiesTest.java
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/test/runtime/modules/IgnoreModulePropertiesTest.java	Thu Mar 09 16:58:45 2017 +0100
+++ b/test/runtime/modules/IgnoreModulePropertiesTest.java	Mon Mar 13 16:23:17 2017 -0400
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -44,7 +44,7 @@
         ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(
             "-D" + prop + "=" + value, "-version");
         OutputAnalyzer output = new OutputAnalyzer(pb.start());
-        output.shouldContain("java version ");
+        output.shouldContain(" version ");
         output.shouldHaveExitValue(0);
 
         // Ensure that the property and its value aren't available.