26 import java.util.ArrayList;
27 import java.util.List;
28 import java.util.Objects;
29 import java.util.concurrent.Semaphore;
30 import java.util.concurrent.TimeUnit;
31
32 import org.testng.Assert;
33 import org.testng.TestNG;
34 import org.testng.annotations.Test;
35 import org.testng.annotations.BeforeSuite;
36 import org.testng.annotations.DataProvider;
37
38 import jdk.test.lib.Platform;
39 import jdk.test.lib.Utils;
40
41 import sun.misc.Signal;
42 import sun.misc.SignalHandler;
43
44 /*
45 * @test
46 * @library /test/lib/share/classes
47 * @modules jdk.unsupported
48 * java.base/jdk.internal.misc
49 * @build jdk.test.lib.Platform jdk.test.lib.Utils
50 * @run testng/othervm -Xrs -DXrs=true SunMiscSignalTest
51 * @run testng/othervm SunMiscSignalTest
52 * @summary sun.misc.Signal test
53 */
54
55 @Test
56 public class SunMiscSignalTest {
57
58 // Set to true to enable additional debug output
59 static boolean debug = true;
60
61 // True to test while running with -Xrs
62 static boolean RUNNING_WITH_Xrs = Boolean.getBoolean("Xrs");
63
64 /**
65 * Print a debug message if enabled.
66 *
|
26 import java.util.ArrayList;
27 import java.util.List;
28 import java.util.Objects;
29 import java.util.concurrent.Semaphore;
30 import java.util.concurrent.TimeUnit;
31
32 import org.testng.Assert;
33 import org.testng.TestNG;
34 import org.testng.annotations.Test;
35 import org.testng.annotations.BeforeSuite;
36 import org.testng.annotations.DataProvider;
37
38 import jdk.test.lib.Platform;
39 import jdk.test.lib.Utils;
40
41 import sun.misc.Signal;
42 import sun.misc.SignalHandler;
43
44 /*
45 * @test
46 * @library /test/lib
47 * @modules jdk.unsupported
48 * java.base/jdk.internal.misc
49 * @build jdk.test.lib.Platform jdk.test.lib.Utils
50 * @run testng/othervm -Xrs -DXrs=true SunMiscSignalTest
51 * @run testng/othervm SunMiscSignalTest
52 * @summary sun.misc.Signal test
53 */
54
55 @Test
56 public class SunMiscSignalTest {
57
58 // Set to true to enable additional debug output
59 static boolean debug = true;
60
61 // True to test while running with -Xrs
62 static boolean RUNNING_WITH_Xrs = Boolean.getBoolean("Xrs");
63
64 /**
65 * Print a debug message if enabled.
66 *
|