jdk/test/tools/launcher/Arrrghs.java
changeset 30684 ac2a15333983
parent 28424 3e9d7d7dd362
child 37540 e92d95400f31
equal deleted inserted replaced
30683:a69fe0acc0ab 30684:ac2a15333983
    22  */
    22  */
    23 
    23 
    24 /**
    24 /**
    25  * @test
    25  * @test
    26  * @bug 5030233 6214916 6356475 6571029 6684582 6742159 4459600 6758881 6753938
    26  * @bug 5030233 6214916 6356475 6571029 6684582 6742159 4459600 6758881 6753938
    27  *      6894719 6968053 7151434 7146424 8007333
    27  *      6894719 6968053 7151434 7146424 8007333 8077822
    28  * @summary Argument parsing validation.
    28  * @summary Argument parsing validation.
    29  * @compile -XDignore.symbol.file Arrrghs.java
    29  * @compile -XDignore.symbol.file Arrrghs.java
    30  * @run main/othervm Arrrghs
    30  * @run main/othervm Arrrghs
    31  */
    31  */
    32 
    32 
   302         if (!tr.isOK()) {
   302         if (!tr.isOK()) {
   303             System.out.println(tr);
   303             System.out.println(tr);
   304             throw new RuntimeException("Error: compiling java wildcards");
   304             throw new RuntimeException("Error: compiling java wildcards");
   305         }
   305         }
   306 
   306 
       
   307         // test if javac (the command) can compile *.java with a vmoption
       
   308         tr = doExec(javacCmd, "-cp", ".",
       
   309                     "-J-showversion", "-J-Dsomeproperty=foo",
       
   310                     libDir.getName() + File.separator + "*.java");
       
   311         if (!tr.isOK()) {
       
   312             System.out.println(tr);
       
   313             throw new RuntimeException("Error: compiling java wildcards with vmoptions");
       
   314         }
       
   315 
       
   316 
   307         // use the jar cmd to create jars using the ? wildcard
   317         // use the jar cmd to create jars using the ? wildcard
   308         File jarFoo = new File(libDir, "Foo.jar");
   318         File jarFoo = new File(libDir, "Foo.jar");
   309         tr = doExec(jarCmd, "cvf", jarFoo.getAbsolutePath(), "lib" + File.separator + "F?o.class");
   319         tr = doExec(jarCmd, "cvf", jarFoo.getAbsolutePath(), "lib" + File.separator + "F?o.class");
   310         if (!tr.isOK()) {
   320         if (!tr.isOK()) {
   311             System.out.println(tr);
   321             System.out.println(tr);