use of teammates.ui.controller.AdminAccountDetailsPageAction in project teammates by TEAMMATES.
the class AdminAccountDetailsPageActionTest method testExecuteAndPostProcess.
@Override
@Test
public void testExecuteAndPostProcess() {
______TS("case: view instructor account details");
InstructorAttributes instructor1OfCourse1 = typicalBundle.instructors.get("instructor1OfCourse1");
String[] submissionParams = new String[] { Const.ParamsNames.INSTRUCTOR_ID, instructor1OfCourse1.googleId };
final String adminUserId = "admin.user";
gaeSimulation.loginAsAdmin(adminUserId);
AdminAccountDetailsPageAction action = getAction(submissionParams);
ShowPageResult result = getShowPageResult(action);
assertEquals("", result.getStatusMessage());
assertEquals(getPageResultDestination(Const.ViewURIs.ADMIN_ACCOUNT_DETAILS, false, adminUserId), result.getDestinationWithParams());
assertFalse(result.isError);
AdminAccountDetailsPageData data = (AdminAccountDetailsPageData) result.data;
assertEquals(instructor1OfCourse1.googleId, data.getAccountInformation().googleId);
}
Aggregations