author | ykantser |
Thu, 07 May 2015 09:11:49 +0200 | |
changeset 30376 | 2ccf2cf7ea48 |
parent 25217 | 2d687ea8608a |
child 34324 | 19a97dc4cb26 |
permissions | -rw-r--r-- |
25217
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
1 |
/* |
30376
2ccf2cf7ea48
8078896: Add @modules as needed to the jdk_svc tests
ykantser
parents:
25217
diff
changeset
|
2 |
* Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. |
25217
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
4 |
* |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
5 |
* This code is free software; you can redistribute it and/or modify it |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
7 |
* published by the Free Software Foundation. |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
8 |
* |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
9 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
10 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
11 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
12 |
* version 2 for more details (a copy is included in the LICENSE file that |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
13 |
* accompanied this code). |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
14 |
* |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
15 |
* You should have received a copy of the GNU General Public License version |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
16 |
* 2 along with this work; if not, write to the Free Software Foundation, |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
17 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
18 |
* |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
19 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
20 |
* or visit www.oracle.com if you need additional information or have any |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
21 |
* questions. |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
22 |
*/ |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
23 |
|
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
24 |
import jdk.testlibrary.OutputAnalyzer; |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
25 |
import jdk.testlibrary.ProcessTools; |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
26 |
|
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
27 |
/* @test |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
28 |
* @bug 4914611 |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
29 |
* @summary Test for JDWP: -agentlib:jdwp=suspend=n hanging |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
30 |
* @library /lib/testlibrary |
30376
2ccf2cf7ea48
8078896: Add @modules as needed to the jdk_svc tests
ykantser
parents:
25217
diff
changeset
|
31 |
* @modules java.management |
25217
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
32 |
* @build jdk.testlibarary.* |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
33 |
* @compile -g HelloWorld.java |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
34 |
* @run driver SuspendNoFlagTest |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
35 |
*/ |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
36 |
public class SuspendNoFlagTest { |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
37 |
|
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
38 |
private static final String TEST_CLASSES = System.getProperty( |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
39 |
"test.classes", "."); |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
40 |
|
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
41 |
public static void main(String[] args) throws Throwable { |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
42 |
OutputAnalyzer output = ProcessTools.executeTestJvm("-classpath", |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
43 |
TEST_CLASSES, |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
44 |
"-agentlib:jdwp=transport=dt_socket,server=y,suspend=n", |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
45 |
"HelloWorld"); |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
46 |
output.shouldHaveExitValue(0); |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
47 |
} |
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
48 |
|
2d687ea8608a
8048892: TEST_BUG: shell script tests need to be change to not use retired @debuggeeVMOptions mechanism
ykantser
parents:
diff
changeset
|
49 |
} |