com.atlassian.studio.haup.pageobjects
Class ViewUserWithAppPermissionsPage

java.lang.Object
  extended by com.atlassian.jira.pageobjects.pages.AbstractJiraPage
      extended by com.atlassian.jira.pageobjects.pages.admin.user.ViewUserPage
          extended by com.atlassian.studio.haup.pageobjects.ViewUserWithAppPermissionsPage
All Implemented Interfaces:
com.atlassian.pageobjects.Page

public class ViewUserWithAppPermissionsPage
extends ViewUserPage

Represents HAUP-modified ViewUser page which includes the application permissions.


Field Summary
protected  com.atlassian.pageobjects.elements.PageElement footer
           
 
Fields inherited from class com.atlassian.jira.pageobjects.pages.AbstractJiraPage
body, driver, elementFinder, footerElement, metaElement, pageBinder
 
Constructor Summary
ViewUserWithAppPermissionsPage()
           
 
Method Summary
 Set<SupportedApplication> getGrantedApplications()
          Gets the granted applications.
 RemainingAccessSection getRemainingAccessSection()
          Returns the remaining access section on the page.
 ViewUserWithAppPermissionsPage goEditMode()
          Switches to edit mode.
 ViewUserWithAppPermissionsPage goViewMode()
          Switches to view mode.
 ViewUserWithAppPermissionsPage grantAccess(SupportedApplication application)
          Grants the user access to the specified application.
 boolean isApplicationEditCheckboxPresentForApp(SupportedApplication application)
          Checks whether the UI displays a 'grant/revoke access' checkbox for the specified app
 boolean isApplicationSectionVisible()
          Checks whether the UI displays the 'application' section
 boolean isButtonPanelVisible()
          Checks whether the UI is currently in edit mode.
 boolean isGranted(SupportedApplication application)
          Checks whether the user has access to the specified application.
 boolean isRemainingValuePresentForApp(SupportedApplication application)
          Checks whether the UI displays a remaining access count for the specified app
 ViewUserWithAppPermissionsPage revokeAccess(SupportedApplication application)
          Revokes the user access to the specified application.
 RevokeAccessWarningMessageDialog revokeAccessExpectingWarningMessage(SupportedApplication application)
          Revokes the user access to the specified application, and expects a warning message dialog.
 ViewUserWithAppPermissionsPage setAccess(SupportedApplication application, boolean hasAccess)
          Sets whether the user has access to the specified application.
 ViewUserWithAppPermissionsPage submitApplications()
          Saves the selected accessible applications.
 
Methods inherited from class com.atlassian.jira.pageobjects.pages.admin.user.ViewUserPage
editDetails, editGroups, editProperties, getCurrentFailedLoginCount, getEmail, getFullname, getLastFailedLogin, getLastLogin, getLoginCount, getPreviousLogin, getTotalFailedLoginCount, getUrl, getUsername, gotoDeleteUserPage, isAt, setPassword, viewProjectsRoles, viewPublicProfile
 
Methods inherited from class com.atlassian.jira.pageobjects.pages.AbstractJiraPage
back, createXsrfUrl, doWait, execKeyboardShortcut, getHeader, getPageTitle, getXsrfToken, isAdmin, isLoggedIn
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

footer

protected com.atlassian.pageobjects.elements.PageElement footer
Constructor Detail

ViewUserWithAppPermissionsPage

public ViewUserWithAppPermissionsPage()
Method Detail

setAccess

public ViewUserWithAppPermissionsPage setAccess(SupportedApplication application,
                                                boolean hasAccess)
Sets whether the user has access to the specified application. Only works in edit mode goEditMode().

Parameters:
application - application
hasAccess - true if the user should have access to the application. Otherwise false.
Returns:
current page

grantAccess

public ViewUserWithAppPermissionsPage grantAccess(SupportedApplication application)
Grants the user access to the specified application. Only works in edit mode goEditMode().

Parameters:
application - application
Returns:
current page

revokeAccess

public ViewUserWithAppPermissionsPage revokeAccess(SupportedApplication application)
Revokes the user access to the specified application. Only works in edit mode goEditMode().

Parameters:
application - application
Returns:
current page

revokeAccessExpectingWarningMessage

public RevokeAccessWarningMessageDialog revokeAccessExpectingWarningMessage(SupportedApplication application)
Revokes the user access to the specified application, and expects a warning message dialog. Only works in edit mode goEditMode().

Parameters:
application - application
Returns:
a warning message dialog

isGranted

public boolean isGranted(SupportedApplication application)
Checks whether the user has access to the specified application. Only works in edit mode goEditMode().

Parameters:
application - application
Returns:
true if the user has access to the specified application

isButtonPanelVisible

public boolean isButtonPanelVisible()
Checks whether the UI is currently in edit mode.

Returns:
true if in edit mode

isApplicationEditCheckboxPresentForApp

public boolean isApplicationEditCheckboxPresentForApp(SupportedApplication application)
Checks whether the UI displays a 'grant/revoke access' checkbox for the specified app

Parameters:
application -
Returns:
true if checkbox present

isRemainingValuePresentForApp

public boolean isRemainingValuePresentForApp(SupportedApplication application)
Checks whether the UI displays a remaining access count for the specified app

Parameters:
application -
Returns:
true if remaining access count present

isApplicationSectionVisible

public boolean isApplicationSectionVisible()
Checks whether the UI displays the 'application' section

Returns:
true if in edit mode

goEditMode

public ViewUserWithAppPermissionsPage goEditMode()
Switches to edit mode.

Returns:
page with edit mode enabled

goViewMode

public ViewUserWithAppPermissionsPage goViewMode()
Switches to view mode.

Returns:
page with view mode

submitApplications

public ViewUserWithAppPermissionsPage submitApplications()
Saves the selected accessible applications.

Returns:
page after submitting the applications

getGrantedApplications

public Set<SupportedApplication> getGrantedApplications()
Gets the granted applications. Only works in view mode goViewMode().

Returns:
set of granted applications, never null.

getRemainingAccessSection

public RemainingAccessSection getRemainingAccessSection()
Returns the remaining access section on the page. Only valid in edit mode goEditMode().

Returns:
remaining access section


Copyright © 2002-2012 Atlassian. All Rights Reserved.