17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25
26 /*
27 * @test
28 * @summary Test case sensitive aspect of comparing class paths
29 * between dump time and archive use time
30 * @requires vm.cds
31 * @library /test/lib
32 * @modules java.base/jdk.internal.misc
33 * java.management
34 * jdk.jartool/sun.tools.jar
35 * @requires os.family != "mac"
36 * @compile test-classes/Hello.java
37 * @run main CaseSensitiveClassPath
38 */
39
40 import java.nio.file.FileAlreadyExistsException;
41 import java.nio.file.Files;
42 import java.nio.file.Path;
43 import java.nio.file.Paths;
44 import java.nio.file.StandardCopyOption;
45 import jdk.test.lib.Platform;
46 import jdk.test.lib.process.OutputAnalyzer;
47
48
49 // Excluded from running on MAC: a more comprehensive case sensitivity detection
50 // and fix mechanism is needed, which is planned to be implemented in the future.
51 public class CaseSensitiveClassPath {
52 public static void main(String[] args) throws Exception {
53 String appJar = JarBuilder.getOrCreateHelloJar();
54 String appJarUpper = appJar.replace("hello", "Hello");
55
56 OutputAnalyzer out = TestCommon.dump(appJar, TestCommon.list("Hello"));
57 TestCommon.checkDump(out);
|
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25
26 /*
27 * @test
28 * @summary Test case sensitive aspect of comparing class paths
29 * between dump time and archive use time
30 * @requires vm.cds
31 * @library /test/lib
32 * @modules java.base/jdk.internal.misc
33 * java.management
34 * jdk.jartool/sun.tools.jar
35 * @requires os.family != "mac"
36 * @compile test-classes/Hello.java
37 * @run driver CaseSensitiveClassPath
38 */
39
40 import java.nio.file.FileAlreadyExistsException;
41 import java.nio.file.Files;
42 import java.nio.file.Path;
43 import java.nio.file.Paths;
44 import java.nio.file.StandardCopyOption;
45 import jdk.test.lib.Platform;
46 import jdk.test.lib.process.OutputAnalyzer;
47
48
49 // Excluded from running on MAC: a more comprehensive case sensitivity detection
50 // and fix mechanism is needed, which is planned to be implemented in the future.
51 public class CaseSensitiveClassPath {
52 public static void main(String[] args) throws Exception {
53 String appJar = JarBuilder.getOrCreateHelloJar();
54 String appJarUpper = appJar.replace("hello", "Hello");
55
56 OutputAnalyzer out = TestCommon.dump(appJar, TestCommon.list("Hello"));
57 TestCommon.checkDump(out);
|