J. Duke | 319a3b9 | 2007-12-01 00:00:00 +0000 | [diff] [blame^] | 1 | /* |
| 2 | @test |
| 3 | @bug 6599601 |
| 4 | @summary tests that a simple GUI application runs without any |
| 5 | exceptions thrown |
| 6 | @author Artem.Ananiev area=awt.Toolkit |
| 7 | @run main SecurityTest2 |
| 8 | */ |
| 9 | |
| 10 | import java.awt.*; |
| 11 | |
| 12 | public class SecurityTest2 |
| 13 | { |
| 14 | public static void main(String[] args) |
| 15 | { |
| 16 | System.setSecurityManager(new SecurityManager()); |
| 17 | |
| 18 | try |
| 19 | { |
| 20 | Frame f = new Frame(); |
| 21 | f.setVisible(true); |
| 22 | f.dispose(); |
| 23 | } |
| 24 | catch (Exception z) |
| 25 | { |
| 26 | throw new RuntimeException("Test FAILED because of some Exception thrown", z); |
| 27 | } |
| 28 | } |
| 29 | } |