(null, null, null)));
((Status)null, null, null)));
  public final void testGrantActingAs()  throws    SignetAuthorityException,    ObjectNotFoundException  {    // We'll attempt to have subject 1 grant a privilege to subject 2, while    // "acting as" subject 0.        Subject subject0      = signet.getSubject          (Signet.DEFAULT_SUBJECT_TYPE_ID,           fixtures.makeSubjectId(0));    Subject subject1      = signet.getSubject          (Signet.DEFAULT_SUBJECT_TYPE_ID,           fixtures.makeSubjectId(1));    Subject subject2      = signet.getSubject          (Signet.DEFAULT_SUBJECT_TYPE_ID,           fixtures.makeSubjectId(2));        PrivilegedSubject pSubject0 = signet.getPrivilegedSubject(subject0);    PrivilegedSubject pSubject1 = signet.getPrivilegedSubject(subject1);    PrivilegedSubject pSubject2 = signet.getPrivilegedSubject(subject2);        Assignment oldAssignment      = (Assignment)          (Common.getFirstSetMember            (pSubject0.getAssignmentsReceived              (null, null, null)));    Set oldLimitValues = oldAssignment.getLimitValues();        pSubject1.setActingAs(pSubject0);        Assignment newAssignment      = pSubject1.grant          (pSubject2, // grantee           oldAssignment.getScope(),           oldAssignment.getFunction(),           oldLimitValues,           false, // canUse           true, // canGrant           new Date(),  // effective immediately           null);       // no expiration date        pSubject1.setActingAs(null);        assertNotNull(newAssignment);    assertEquals(pSubject0, newAssignment.getGrantor());    assertEquals(pSubject1, newAssignment.getProxy());    assertEquals(pSubject2, newAssignment.getGrantee());  }