< prev index next >

test/jdk/tools/launcher/ExecutionEnvironment.java

Print this page
rev 59383 : [mq]: final

*** 1,7 **** /* ! * Copyright (c) 2009, 2019, 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 * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. --- 1,7 ---- /* ! * Copyright (c) 2009, 2020, 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 * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation.
*** 172,218 **** /* * This test ensures that LD_LIBRARY_PATH* values are interpreted by the VM * and the expected java.library.path behaviour. * For Generic platforms (All *nixes): * * All LD_LIBRARY_PATH variable should be on java.library.path - * For Solaris 32-bit - * * The LD_LIBRARY_PATH_32 should override LD_LIBRARY_PATH if specified - * For Solaris 64-bit - * * The LD_LIBRARY_PATH_64 should override LD_LIBRARY_PATH if specified */ @Test void testJavaLibraryPath() { TestResult tr; Map<String, String> env = new HashMap<>(); - if (TestHelper.isSolaris) { - // no override - env.clear(); - env.put(LD_LIBRARY_PATH, LD_LIBRARY_PATH_VALUE); - tr = doExec(env, javaCmd, "-jar", testJarFile.getAbsolutePath()); - verifyJavaLibraryPathGeneric(tr); - - env.clear(); - for (String x : LD_PATH_STRINGS) { - String pairs[] = x.split("="); - env.put(pairs[0], pairs[1]); - } - - // verify the override occurs for 64-bit system - tr = doExec(env, javaCmd, "-jar", testJarFile.getAbsolutePath()); - verifyJavaLibraryPathOverride(tr, false); - } else { for (String x : LD_PATH_STRINGS) { String pairs[] = x.split("="); env.put(pairs[0], pairs[1]); } tr = doExec(env, javaCmd, "-jar", testJarFile.getAbsolutePath()); verifyJavaLibraryPathGeneric(tr); } - } private void verifyJavaLibraryPathGeneric(TestResult tr) { if (!tr.matches("java.library.path=.*" + LD_LIBRARY_PATH_VALUE + ".*")) { flagError(tr, "testJavaLibraryPath: java.library.path does not contain " + LD_LIBRARY_PATH_VALUE); --- 172,196 ----
< prev index next >