test/lib/jdk/test/lib/cds/CDSTestUtils.java
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File open Sdiff test/lib/jdk/test/lib/cds

test/lib/jdk/test/lib/cds/CDSTestUtils.java

Print this page




 194             return this;
 195         }
 196 
 197 
 198         public Result assertNormalExit(String... matches) throws Exception {
 199             if (!hasMappingFailure) {
 200                 checkMatches(output, matches);
 201                 output.shouldHaveExitValue(0);
 202             }
 203             return this;
 204         }
 205 
 206         public Result assertAbnormalExit(String... matches) throws Exception {
 207             if (!hasMappingFailure) {
 208                 checkMatches(output, matches);
 209                 output.shouldNotHaveExitValue(0);
 210             }
 211 
 212             return this;
 213         }
 214 
 215         public OutputAnalyzer getOutput() {
 216             return output;
 217         }
 218     }
 219 
 220     // Specify this property to copy sdandard output of the child test process to
 221     // the parent/main stdout of the test.
 222     // By default such output is logged into a file, and is copied into the main stdout.
 223     public static final boolean CopyChildStdoutToMainStdout =
 224         Boolean.valueOf(System.getProperty("test.cds.copy.child.stdout", "true"));
 225 
 226     // This property is passed to child test processes
 227     public static final String TestTimeoutFactor = System.getProperty("test.timeout.factor", "1.0");
 228 
 229     public static final String UnableToMapMsg =
 230         "Unable to map shared archive: test did not complete; assumed PASS";
 231 
 232     // Create bootstrap CDS archive,
 233     // use extra JVM command line args as a prefix.
 234     // For CDS tests specifying prefix makes more sense than specifying suffix, since
 235     // normally there are no classes or arguments to classes, just "-version"
 236     // To specify suffix explicitly use CDSOptions.addSuffix()
 237     public static OutputAnalyzer createArchive(String... cliPrefix)




 194             return this;
 195         }
 196 
 197 
 198         public Result assertNormalExit(String... matches) throws Exception {
 199             if (!hasMappingFailure) {
 200                 checkMatches(output, matches);
 201                 output.shouldHaveExitValue(0);
 202             }
 203             return this;
 204         }
 205 
 206         public Result assertAbnormalExit(String... matches) throws Exception {
 207             if (!hasMappingFailure) {
 208                 checkMatches(output, matches);
 209                 output.shouldNotHaveExitValue(0);
 210             }
 211 
 212             return this;
 213         }




 214     }
 215 
 216     // Specify this property to copy sdandard output of the child test process to
 217     // the parent/main stdout of the test.
 218     // By default such output is logged into a file, and is copied into the main stdout.
 219     public static final boolean CopyChildStdoutToMainStdout =
 220         Boolean.valueOf(System.getProperty("test.cds.copy.child.stdout", "true"));
 221 
 222     // This property is passed to child test processes
 223     public static final String TestTimeoutFactor = System.getProperty("test.timeout.factor", "1.0");
 224 
 225     public static final String UnableToMapMsg =
 226         "Unable to map shared archive: test did not complete; assumed PASS";
 227 
 228     // Create bootstrap CDS archive,
 229     // use extra JVM command line args as a prefix.
 230     // For CDS tests specifying prefix makes more sense than specifying suffix, since
 231     // normally there are no classes or arguments to classes, just "-version"
 232     // To specify suffix explicitly use CDSOptions.addSuffix()
 233     public static OutputAnalyzer createArchive(String... cliPrefix)


test/lib/jdk/test/lib/cds/CDSTestUtils.java
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File