AttributeChangeNotificationFilterTest.java 文件源码

java
阅读 23 收藏 0 点赞 0 评论 0

项目:freeVM 作者:
/**
 * Test for the method enableAttribute(java.lang.String)
 * 
 * @see javax.management.AttributeChangeNotificationFilter#enableAttribute(java.lang.String)
 */
public final void testEnableAttribute() {
    assertNotNull("Notification has not been received!", n);

    // Test exception.
    f = new AttributeChangeNotificationFilter();
    try {
        f.enableAttribute(null);
        fail("IllegalArgumentException not thrown!");
    } catch (Throwable ex) {
        assertTrue("Wrong exception thrown: " + ex,
            (ex instanceof IllegalArgumentException));
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号