Code example for Permissions

0
@SuppressWarnings("deprecation") 
@TestTargetClass(Signer.class)
public class SignerTest extends TestCase {
 
    public static class MySecurityManager extends SecurityManager {
        public Permissions denied = new Permissions();
        public void checkPermission(Permission permission){
            if (denied!=null && denied.implies(permission)) throw new SecurityException();
        } 
    } 
 
    /** 
     * @tests java.security.Signer#toString() 
     */ 
    @TestTargetNew( 
        level = TestLevel.COMPLETE, 
        notes = "", 
        method = "toString", 
        args = {} 
    ) 
    public void test_toString() throws Exception {