@Test
  public void canPauseShouldBeFalseForUnauthorizedAccess() throws Exception {
    configHelper.addSecurityWithAdminConfig();
    configHelper.setOperatePermissionForGroup("defaultGroup", "jez");

    JsonMap jsonMap = requestPipelineHistoryPage();
    assertThat(getItemInJson(jsonMap, "canPause"), is("false"));
  }
  @Test
  public void canPauseShouldBeTrueForAuthorizedAccess() throws Exception {
    configHelper.addSecurityWithAdminConfig();
    configHelper.setOperatePermissionForGroup(
        "defaultGroup", CaseInsensitiveString.str(Username.ANONYMOUS.getUsername()));

    JsonMap jsonMap = requestPipelineHistoryPage();
    assertThat(getItemInJson(jsonMap, "canPause"), is("true"));
  }
  @Test
  public void canForceShouldBeTrueForAuthorizedUser() throws Exception {
    configHelper.addSecurityWithAdminConfig();
    fixture.configStageAsManualApprovalWithApprovedUsers(fixture.devStage, "userA");

    login("userA", "");
    JsonMap jsonMap = requestPipelineHistoryPage();
    assertThat(getItemInJson(jsonMap, "canForce"), is("true"));
  }
  @Test
  public void canForceShouldBeFalseForUnauthorizedAccess() throws Exception {
    configHelper.addSecurityWithAdminConfig();
    fixture.configStageAsManualApprovalWithApprovedUsers(fixture.devStage, "user");

    fixture.createPipelineWithFirstStagePassedAndSecondStageHasNotStarted();

    JsonMap jsonMap = requestPipelineHistoryPage();
    assertThat(getItemInJson(jsonMap, "canForce"), is("false"));
  }