question: public void testClearPassword ( ) { char [ ] password = new char [ ] { '1' , '2' , '3' , '4' , '5' } ; PBEKeySpec pbeks = new PBEKeySpec ( password ) ; pbeks . clearPassword ( ) ; try { pbeks . getPassword ( ) ; fail ( "An IllegalStateException should be was thrown " + "after the clearing the password." ) ; } catch ( IllegalStateException e ) { } }
target:  clearPassword() method testing. Tests that internal copy of password is cleared after the method call.