AnyDebuggeeTest.java revision 2362
1703N/A * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 0N/A * published by the Free Software Foundation. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 1472N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 1472N/A * or visit www.oracle.com if you need additional information or have any 1879N/A * @summary ReferenceType.nestedTypes() is too slow 1879N/A * @run build TestScaffold VMConnection TargetListener TargetAdapter 1879N/A * @run main AnyDebuggeeeTest 0N/A * This test is intended to be run manually to investigate behaviors; 0N/A * it is not an actual test of any specific functionality, it just 0N/A * allows you to run the debugger part of this test on any debuggee. 1703N/A * As set up, it prints the time to find all nested types and all 1703N/A * subclasses in the debuggee, and so can be used to verify the 0N/A * For other investigations, edit this test to do whatever you want. 0N/A * To run this test do this: 0N/A * runregress -no AnyDebuggeeTest <cmd line options> 0N/A * where <cmd line options> are the options to be used to 0N/A * launch the debuggee, with the classname prefixed with @@. 1703N/A * For example, this would run java2d demo as the debuggee: 0N/A * -client @@java2d.Java2Demo' 1703N/A * If <cmd line options> is not specified, then the AnyDebuggeeTarg class below 0N/A * is run as the debuggee. 1703N/A /********** test program **********/ 1703N/A * If args contains @@xxxx, then that is the 1703N/A * name of the class we are to run. 1703N/A * to determine targetClass and mainThread 1703N/A // Let debuggee run for awhile to get classes loaded * deal with results of test * if anything has called failure("foo") testFailed will be true println(
"AnyDebuggeeTest: passed");
throw new Exception(
"AnyDebuggeeTest: failed");