builder.addAttribute("affiliation", newAffiliation.toString());
}
if(newRole != null) {
builder.addAttribute("role", newRole.toString());
}
builder.endInnerElement();
XMLElement expectedInner = builder.build();
assertErrorStanza(result, "iq", ROOM2_JID, OCCUPANT1_JID, StanzaErrorType.CANCEL, expectedError, expectedInner);
}