1 /* |
1 /* |
2 * Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2014, 2019, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
70 |
70 |
71 if (skipTestCase(testEntry)) |
71 if (skipTestCase(testEntry)) |
72 continue; |
72 continue; |
73 |
73 |
74 OutputAnalyzer dumpOutput = TestCommon.dump(appJar, classList, testEntry); |
74 OutputAnalyzer dumpOutput = TestCommon.dump(appJar, classList, testEntry); |
75 TestCommon.checkDump(dumpOutput, "Loading classes to share"); |
75 if (!TestCommon.isDynamicArchive()) { |
|
76 TestCommon.checkDump(dumpOutput, "Loading classes to share"); |
|
77 } else { |
|
78 if (testEntry.contains("ObjectAlignmentInBytes")) { |
|
79 dumpOutput.shouldHaveExitValue(1) |
|
80 .shouldMatch("The shared archive file's ObjectAlignmentInBytes of .* does not equal the current ObjectAlignmentInBytes of"); |
|
81 } else { |
|
82 TestCommon.checkDump(dumpOutput, "Loading classes to share"); |
|
83 } |
|
84 } |
76 |
85 |
77 OutputAnalyzer execOutput = TestCommon.exec(appJar, testEntry, "Hello"); |
86 if ((TestCommon.isDynamicArchive() && !testEntry.contains("ObjectAlignmentInBytes")) || |
78 TestCommon.checkExec(execOutput, "Hello World"); |
87 !TestCommon.isDynamicArchive()) { |
|
88 OutputAnalyzer execOutput = TestCommon.exec(appJar, testEntry, "Hello"); |
|
89 TestCommon.checkExec(execOutput, "Hello World"); |
|
90 } |
79 } |
91 } |
80 |
92 |
81 for (int i=0; i<2; i++) { |
93 for (int i=0; i<2; i++) { |
82 String g1Flag, serialFlag; |
94 String g1Flag, serialFlag; |
83 |
95 |