コード例 #1
0
  @Test
  public void test_OnlyAdminAllowed_ErrorResponse() throws Exception {
    this.userName = UserTransportBuilder.USER1_NAME;
    this.userPassword = UserTransportBuilder.USER1_PASSWORD;

    final ErrorResponse actual =
        super.callUsecaseWithoutContent(
            "/" + PostingAccountTransportBuilder.POSTING_ACCOUNT1_ID,
            this.method,
            false,
            ErrorResponse.class);

    Assert.assertEquals(new Integer(ErrorCode.USER_IS_NO_ADMIN.getErrorCode()), actual.getCode());
  }