Code example for InvalidKeySpecException

Methods: getCause, getMessage

0
            assertNull("getCause() must return null", tE.getCause());
        } 
    } 
 
    /** 
     * Test for <code>InvalidKeySpecException(String)</code> constructor 
     * Assertion: constructs InvalidKeySpecException when <code>msg</code> is 
     * null 
     */ 
    @TestTargetNew( 
        level = TestLevel.PARTIAL_COMPLETE, 
        notes = "Verifies null as a parameter.", 
        method = "InvalidKeySpecException", 
        args = {java.lang.String.class}
    ) 
    public void testInvalidKeySpecException03() { 
        String msg = null;
        InvalidKeySpecException tE = new InvalidKeySpecException(msg);
        assertNull("getMessage() must return null.", tE.getMessage());
        assertNull("getCause() must return null", tE.getCause());
    }