test/jdk/tools/launcher/Settings.java
author bobv
Tue, 12 Jun 2018 18:51:45 -0400
changeset 50545 292a4a87c321
parent 47216 71c04702a3d5
child 54541 9ff8d175035d
permissions -rw-r--r--
8203357: Container Metrics Reviewed-by: mchung, dholmes, mseledtsov, rehn
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     1
/*
46844
36796fc011d8 8176797: [TESTBUG] tools/launcher/Settings.java -Xss size is too small
cjplummer
parents: 37540
diff changeset
     2
 * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved.
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     4
 *
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     7
 * published by the Free Software Foundation.
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     8
 *
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    13
 * accompanied this code).
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    14
 *
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    18
 *
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    21
 * questions.
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    22
 */
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    23
import java.io.File;
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    24
import java.io.IOException;
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    25
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    26
/*
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    27
 * @test
11363
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
    28
 * @bug 6994753 7123582
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    29
 * @summary tests -XshowSettings options
45944
882cea808912 8179292: a number of launcher tests fail when run with --limit-modules due to CNFE: javax.tools.ToolProvider
anazarov
parents: 37540
diff changeset
    30
 * @modules jdk.compiler
882cea808912 8179292: a number of launcher tests fail when run with --limit-modules due to CNFE: javax.tools.ToolProvider
anazarov
parents: 37540
diff changeset
    31
 *          jdk.zipfs
11687
f13cadbb0bb5 7127906: (launcher) convert the launcher regression tests to java
ksrini
parents: 11363
diff changeset
    32
 * @compile -XDignore.symbol.file Settings.java
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    33
 * @run main Settings
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    34
 * @author ksrini
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    35
 */
11687
f13cadbb0bb5 7127906: (launcher) convert the launcher regression tests to java
ksrini
parents: 11363
diff changeset
    36
public class Settings extends TestHelper {
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    37
    private static File testJar = null;
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    38
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    39
    static void init() throws IOException {
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    40
        if  (testJar != null) {
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    41
            return;
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    42
        }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    43
        testJar = new File("test.jar");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    44
        StringBuilder tsrc = new StringBuilder();
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    45
        tsrc.append("public static void main(String... args) {\n");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    46
        tsrc.append("   for (String x : args) {\n");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    47
        tsrc.append("        System.out.println(x);\n");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    48
        tsrc.append("   }\n");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    49
        tsrc.append("}\n");
11687
f13cadbb0bb5 7127906: (launcher) convert the launcher regression tests to java
ksrini
parents: 11363
diff changeset
    50
        createJar(testJar, tsrc.toString());
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    51
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    52
11687
f13cadbb0bb5 7127906: (launcher) convert the launcher regression tests to java
ksrini
parents: 11363
diff changeset
    53
    static void checkContains(TestResult tr, String str) {
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    54
        if (!tr.contains(str)) {
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    55
            System.out.println(tr);
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    56
            throw new RuntimeException(str + " not found");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    57
        }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    58
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    59
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
    60
    static void checkNotContains(TestResult tr, String str) {
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
    61
        if (!tr.notContains(str)) {
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
    62
            System.out.println(tr);
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    63
            throw new RuntimeException(str + " found");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    64
        }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    65
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    66
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    67
    private static final String VM_SETTINGS = "VM settings:";
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    68
    private static final String PROP_SETTINGS = "Property settings:";
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    69
    private static final String LOCALE_SETTINGS = "Locale settings:";
50545
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
    70
    private static final String SYSTEM_SETTINGS = "Operating System Metrics:";
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    71
11687
f13cadbb0bb5 7127906: (launcher) convert the launcher regression tests to java
ksrini
parents: 11363
diff changeset
    72
    static void containsAllOptions(TestResult tr) {
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    73
        checkContains(tr, VM_SETTINGS);
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    74
        checkContains(tr, PROP_SETTINGS);
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    75
        checkContains(tr, LOCALE_SETTINGS);
50545
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
    76
        if (System.getProperty("os.name").contains("Linux")) {
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
    77
            checkContains(tr, SYSTEM_SETTINGS);
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
    78
        }
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    79
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    80
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    81
    static void runTestOptionDefault() throws IOException {
46844
36796fc011d8 8176797: [TESTBUG] tools/launcher/Settings.java -Xss size is too small
cjplummer
parents: 37540
diff changeset
    82
        int stackSize = 256; // in kb
35248
b0665ea22f83 8073139: PPC64: User-visible arch directory and os.arch value on ppc64le cause issues with Java tooling
asmundak
parents: 22602
diff changeset
    83
        if (getArch().equals("ppc64") || getArch().equals("ppc64le")) {
46844
36796fc011d8 8176797: [TESTBUG] tools/launcher/Settings.java -Xss size is too small
cjplummer
parents: 37540
diff changeset
    84
            stackSize = 800;
22602
0d9a07b0d7e9 8028537: PPC64: Updated the JDK regression tests to run on AIX
simonis
parents: 11998
diff changeset
    85
        }
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
    86
        TestResult tr;
11687
f13cadbb0bb5 7127906: (launcher) convert the launcher regression tests to java
ksrini
parents: 11363
diff changeset
    87
        tr = doExec(javaCmd, "-Xms64m", "-Xmx512m",
22602
0d9a07b0d7e9 8028537: PPC64: Updated the JDK regression tests to run on AIX
simonis
parents: 11998
diff changeset
    88
                "-Xss" + stackSize + "k", "-XshowSettings", "-jar", testJar.getAbsolutePath());
7810
d4730191e53c 7002386: (launcher) fix XshowSettings
ksrini
parents: 7297
diff changeset
    89
        containsAllOptions(tr);
d4730191e53c 7002386: (launcher) fix XshowSettings
ksrini
parents: 7297
diff changeset
    90
        if (!tr.isOK()) {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
    91
            System.out.println(tr);
7810
d4730191e53c 7002386: (launcher) fix XshowSettings
ksrini
parents: 7297
diff changeset
    92
            throw new RuntimeException("test fails");
d4730191e53c 7002386: (launcher) fix XshowSettings
ksrini
parents: 7297
diff changeset
    93
        }
11687
f13cadbb0bb5 7127906: (launcher) convert the launcher regression tests to java
ksrini
parents: 11363
diff changeset
    94
        tr = doExec(javaCmd, "-Xms65536k", "-Xmx712m",
46844
36796fc011d8 8176797: [TESTBUG] tools/launcher/Settings.java -Xss size is too small
cjplummer
parents: 37540
diff changeset
    95
                "-Xss" + (stackSize * 1024), "-XshowSettings", "-jar", testJar.getAbsolutePath());
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    96
        containsAllOptions(tr);
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    97
        if (!tr.isOK()) {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
    98
            System.out.println(tr);
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
    99
            throw new RuntimeException("test fails");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   100
        }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   101
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   102
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   103
    static void runTestOptionAll() throws IOException {
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   104
        init();
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   105
        TestResult tr = doExec(javaCmd, "-XshowSettings:all");
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   106
        containsAllOptions(tr);
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   107
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   108
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   109
    static void runTestOptionVM() throws IOException {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   110
        TestResult tr = doExec(javaCmd, "-XshowSettings:vm");
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   111
        checkContains(tr, VM_SETTINGS);
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   112
        checkNotContains(tr, PROP_SETTINGS);
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   113
        checkNotContains(tr, LOCALE_SETTINGS);
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   114
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   115
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   116
    static void runTestOptionProperty() throws IOException {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   117
        TestResult tr = doExec(javaCmd, "-XshowSettings:properties");
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   118
        checkNotContains(tr, VM_SETTINGS);
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   119
        checkContains(tr, PROP_SETTINGS);
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   120
        checkNotContains(tr, LOCALE_SETTINGS);
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   121
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   122
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   123
    static void runTestOptionLocale() throws IOException {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   124
        TestResult tr = doExec(javaCmd, "-XshowSettings:locale");
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   125
        checkNotContains(tr, VM_SETTINGS);
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   126
        checkNotContains(tr, PROP_SETTINGS);
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   127
        checkContains(tr, LOCALE_SETTINGS);
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   128
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   129
50545
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   130
    static void runTestOptionSystem() throws IOException {
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   131
        TestResult tr = doExec(javaCmd, "-XshowSettings:system");
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   132
        if (System.getProperty("os.name").contains("Linux")) {
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   133
            checkNotContains(tr, VM_SETTINGS);
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   134
            checkNotContains(tr, PROP_SETTINGS);
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   135
            checkNotContains(tr, LOCALE_SETTINGS);
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   136
            checkContains(tr, SYSTEM_SETTINGS);
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   137
        } else {
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   138
            // -XshowSettings prints all available settings when
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   139
            // settings argument is not recognized.
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   140
            containsAllOptions(tr);
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   141
        }
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   142
    }
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   143
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   144
    static void runTestBadOptions() throws IOException {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   145
        TestResult tr = doExec(javaCmd, "-XshowSettingsBadOption");
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   146
        checkNotContains(tr, VM_SETTINGS);
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   147
        checkNotContains(tr, PROP_SETTINGS);
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   148
        checkNotContains(tr, LOCALE_SETTINGS);
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   149
        checkContains(tr, "Unrecognized option: -XshowSettingsBadOption");
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   150
    }
11363
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   151
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   152
    static void runTest7123582() throws IOException {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   153
        TestResult tr = doExec(javaCmd, "-XshowSettings", "-version");
11363
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   154
        if (!tr.isOK()) {
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   155
            System.out.println(tr);
11363
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   156
            throw new RuntimeException("test fails");
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   157
        }
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   158
        containsAllOptions(tr);
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   159
    }
09b0c9731145 7123582: (launcher) display the -version and -XshowSettings
ksrini
parents: 7810
diff changeset
   160
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   161
    public static void main(String... args) throws IOException {
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   162
        runTestOptionAll();
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   163
        runTestOptionDefault();
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   164
        runTestOptionVM();
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   165
        runTestOptionProperty();
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   166
        runTestOptionLocale();
50545
292a4a87c321 8203357: Container Metrics
bobv
parents: 47216
diff changeset
   167
        runTestOptionSystem();
37540
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   168
        runTestBadOptions();
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   169
        runTest7123582();
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   170
        if (testExitValue != 0) {
e92d95400f31 8154470: defines.h confused about PROGNAME and JAVA_ARGS
martin
parents: 35248
diff changeset
   171
            throw new Error(testExitValue + " tests failed");
7297
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   172
        }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   173
    }
906c58a8b849 6452854: Provide a flag to print the java configuration
ksrini
parents:
diff changeset
   174
}