10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /*
25 * @test
26 * @bug 6730926
27 * @summary Check behaviour of MBeanServer when postRegister and postDeregister
28 * throw exceptions.
29 * @author Daniel Fuchs
30 * @modules java.management
31 * @compile PostExceptionTest.java
32 * @run main PostExceptionTest
33 */
34
35 import javax.management.*;
36 import java.io.Serializable;
37 import java.net.URL;
38 import java.util.EnumSet;
39 import javax.management.loading.MLet;
40
41 public class PostExceptionTest {
42
43 /**
44 * A test case where we instantiate an ExceptionalWombatMBean (or a
45 * subclass of it) which will throw the exception {@code t} from within
46 * the methods indicated by {@code where}
47 */
48 public static class Case {
49 public final Throwable t;
50 public final EnumSet<WHERE> where;
51 public Case(Throwable t,EnumSet<WHERE> where) {
|
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /*
25 * @test
26 * @bug 6730926
27 * @summary Check behaviour of MBeanServer when postRegister and postDeregister
28 * throw exceptions.
29 * @author Daniel Fuchs
30 *
31 * @run main PostExceptionTest
32 */
33
34 import javax.management.*;
35 import java.io.Serializable;
36 import java.net.URL;
37 import java.util.EnumSet;
38 import javax.management.loading.MLet;
39
40 public class PostExceptionTest {
41
42 /**
43 * A test case where we instantiate an ExceptionalWombatMBean (or a
44 * subclass of it) which will throw the exception {@code t} from within
45 * the methods indicated by {@code where}
46 */
47 public static class Case {
48 public final Throwable t;
49 public final EnumSet<WHERE> where;
50 public Case(Throwable t,EnumSet<WHERE> where) {
|