Class CrowdAcceptanceTestCase
java.lang.Object
com.atlassian.crowd.acceptance.tests.applications.crowd.CrowdWebDriverTest
com.atlassian.crowd.acceptance.utils.CrowdWebTestCase
com.atlassian.crowd.acceptance.tests.applications.crowd.CrowdAcceptanceTestCase
- Direct Known Subclasses:
AbstractDbCachingLoadTest
,ActionAnnotationsInPluginTest
,AddGroupTest
,AnalyticsAcceptanceTest
,AnonymousAccessTest
,ApplicationAccessBasedFilteringTest
,ApplicationOptionsTest
,AutoGroupAdderTest
,BackupRestoreTest
,BambooImporterTest
,BrowseApplicationUsersTest
,ClusterMonitoringAcceptanceTest
,ConfluenceImporterTest
,CrowdConsoleJndiTimeoutUnlimitedWarningTest
,CrowdConsoleTest
,CrowdifiedBambooImporterTest
,CrowdifiedConfluenceImporterTest
,CrowdifiedJiraImporterTest
,CrowdSecurityHeadersIntegrationTest
,CrowdUserConsoleAcceptenceTestCase
,DecoratorModuleTest
,DelegatedDirectoryTest
,DelegatedDirectoryWithNestedGroupsTest
,DirectoryImporterTest
,DirectoryPermissionGroupTest
,DirectoryPermissionRoleTest
,DirectoryPermissionUserTest
,ErrorPageTest
,ExternalLinksProxyServletTest
,ForgedLicenseWarningTest
,GeneralAdministrationTest
,HealthCheckResourceTest
,JiraImporterTest
,LicenseMaintenanceTest
,LoggingProfilingTest
,MailTemplateTest
,OGNLDoubleEvaluationTest
,OGNLInjectionTest
,RecalculateLicenseTest
,RemoteDirectoryNestedGroupTest
,RestCrowdClientTest
,RestXmlParsingTest
,SAMLAuthTest
,SamlConfigBackupRestoreTest
,SessionIdOnAuthenticationTest
,SSOCookieTest
,StatusTest
,Struts2ConfigurationTest
,SystemInfoTest
,UpdateSAMLConfigurationTest
,UserFromGoogleAppsDirectoryImpersonationTest
,UsernameInformationIntegrationTest
,ViewApplicationTest
,ViewOptionsTest
,ViewRoleTest
-
Nested Class Summary
Nested classes/interfaces inherited from class com.atlassian.crowd.acceptance.utils.CrowdWebTestCase
CrowdWebTestCase.GenericPage, CrowdWebTestCase.TestContext
-
Field Summary
Modifier and TypeFieldDescriptionprotected static final String
protected static final String
static final BatchedTestRule
static final String
protected final org.slf4j.Logger
protected TestkitClient
final org.junit.rules.TestName
org.junit.rules.TestRule
protected static String
protected static final String
Fields inherited from class com.atlassian.crowd.acceptance.tests.applications.crowd.CrowdWebDriverTest
applinksClient, BACKUP_RESOURCE, COOKIE_ABSENT, i18n, IMMUTABLE_USER_NAME, IMMUTABLE_USER_PW, JSESSIONID_COOKIE, log, REMEMBER_ME_COOKIE, restAdminClient, SSO_COOKIE, TEST_USER_DISPLAYNAME, TEST_USER_NAME, TEST_USER_PW, testedProduct, webDriverRules
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
_loginAsUser
(String username, String password) void
_logout()
void
void
assertAtLoginForm
(io.restassured.response.Response response) void
void
void
assertMatchInTableBody
(String tableId, String match) void
assertNoMatchInTableBody
(String tableId, String match) void
void
void
void
assertUserInTable
(String username, String fullname, String email) void
assertUserInTable
(String username, String fullname, String email, String alias) void
assertUserNotInTable
(String username, String fullname, String email) void
protected String
doBackup()
Returns file name of the backup.static Properties
int
getUsersCount
(long directoryId) getUsersForDirectory
(long directoryId) void
void
void
void
void
void
void
void
gotoBrowseGroups
(int resultsStart) void
void
gotoBrowsePrincipals
(int resultsStart) void
void
void
void
void
void
void
void
void
void
void
gotoRemovePrincipal
(String principalName, String directoryName) void
void
void
void
void
void
gotoViewApplication
(String applicationName) void
gotoViewApplicationDirectories
(String applicationName) void
gotoViewGroup
(String groupName, String directoryName) void
gotoViewPrincipal
(String principalName, String directoryName) void
Indicate that a test will modify LDAP data.boolean
boolean
protected void
void
void
loginWithRestAndRedirectToStartPage
(String username, String password, boolean rememberMe, List<org.apache.http.NameValuePair> queryParams) protected io.restassured.response.Response
loginWithRestEndpoint
(String username, String password, boolean rememberMe) Logs in using the rest endpoint, does not navigate to page returned by the redirect endpoint.protected io.restassured.response.Response
loginWithRestEndpoint
(String username, String password, boolean rememberMe, List<org.apache.http.NameValuePair> queryParams) Logs in using the rest endpoint, does not navigate to page returned by the redirect endpoint.namesOf
(Iterable<? extends DirectoryEntity> entities) protected io.restassured.response.Response
performRequestWithCookieExchange
(com.google.common.base.Function<io.restassured.specification.RequestSpecification, io.restassured.response.Response> requestPerformer) protected <T> T
protected void
restoreCrowdFromXMLWithoutReloggingIn
(String xmlfilename, boolean checkForError) protected void
void
setUp()
protected org.hamcrest.Matcher<User>
userWithDetails
(String username, String fullname) org.hamcrest.Matcher<UserData>
userWithUsernameAndDisplayName
(String username, String displayName) Methods inherited from class com.atlassian.crowd.acceptance.utils.CrowdWebTestCase
addRequestHeader, assertButtonNotPresent, assertCheckboxNotPresent, assertCheckboxNotSelected, assertCheckboxPresent, assertCheckboxSelected, assertCheckboxSelected, assertElementIsDisabled, assertElementIsEnabled, assertElementNotPresent, assertElementNotPresentByXPath, assertElementPresent, assertElementPresentByXPath, assertErrorNotPresent, assertErrorPresent, assertErrorPresentWithKey, assertFieldErrorPresentWithKey, assertInfoPresent, assertKeyInElement, assertKeyNotPresent, assertKeyPresent, assertKeyPresent, assertKeyPresent, assertLinkNotPresent, assertLinkPresent, assertLinkPresentWithKey, assertMatchInTable, assertRadioOptionNotPresent, assertRadioOptionSelected, assertSelectedOptionEquals, assertSelectedOptionValueEquals, assertSelectOptionsEqual, assertSuccessPresent, assertTableNotPresent, assertTablePresent, assertTableRowCountEquals, assertTextFieldEquals, assertTextInElement, assertTextInTable, assertTextInTable, assertTextNotInTable, assertTextNotInTable, assertTextNotPresent, assertTextPresent, assertTitleEquals, assertTitleMatch, assertTitleNotEquals, assertWarningAndErrorNotPresent, assertWarningNotPresent, beginAt, checkCheckbox, checkCheckbox, clearCookies, clickButton, clickButtonWithText, clickElementByXPath, clickLink, clickLinkInNavbar, clickLinkInNavbarDropdown, clickLinkWithExactText, clickLinkWithKey, clickLinkWithText, clickRadioOption, closeBrowser, disableIpAddressValidation, equalToIgnoringWhiteSpace, findElementWithText, getBaseUrlIPv6, getElementById, getElementByXPath, getElementsByXPath, getElementTextById, getElementTextByXPath, getElementValueByID, getFinder, getLinkInNavbar, getLinkInNavbarDropdown, getMessage, getMessage, getName, getPageSource, getPageText, getPoller, getRadiosFromRadioGroup, getRadioWithValue, getRestAssuredCookies, getTable, getTestContext, getText, getTextForList, gotoPage, isElementWithIdPresent, isTextPresent, scrapeTable, scrapeTable, scrapeTable, selectOption, selectOption, selectOptionBy, selectOptionByValue, seleniumCookieToRestAssuredCookie, setRadioButton, setResourceBundleName, setTextField, setWorkingForm, setWorkingForm, submit, submit, uncheckCheckbox, waitForElementById, waitUntilPageLoad
Methods inherited from class com.atlassian.crowd.acceptance.tests.applications.crowd.CrowdWebDriverTest
assertAtRelativePath, assertAtURIContaining, assertAtURIEndingWith, assertAtUrl, assertHasError, assertHasErrorKey, bind, bind, clearAndInvalidateSsoCookieIfPresent, clearAndInvalidateSsoCookieOrFail, deleteAllCookies, deleteCookie, expectState, getBaseUrl, getBaseUrlWithoutPort, getCookie, getCookieOrThrow, getCurrentUrl, getDriver, getSsoCookieOrFail, getTestkitClient, hasCookie, hasSsoCookie, loginAsExpiredPasswordUser, loginAsNonAdmin, loginAsNonAdmin, loginAsSysAdmin, loginAsSysAdmin, loginAsSysAdminWithRememberMe, loginAsUser, loginExpectingFailure, loginImmutableUser, loginImmutableUser, loginTestUser, loginTestUser, logout, manage, navigateToAndBind, navigateToUrl, restoreBaseSetup, restoreCrowdFromXML, restoreCrowdFromXML, waitForUrl, waitUntilAsyncFinished
-
Field Details
-
USER_DETAILS_TABLE_ID
- See Also:
-
ADMIN_USER
- See Also:
-
ADMIN_PW
- See Also:
-
URL_HOME
-
logger
protected final org.slf4j.Logger logger -
EXPIRED_MAINTENANCE_KEY
- See Also:
-
testkitClient
-
BATCHED_TEST_RULE
-
testName
public final org.junit.rules.TestName testName -
testWatcher
public org.junit.rules.TestRule testWatcher
-
-
Constructor Details
-
CrowdAcceptanceTestCase
public CrowdAcceptanceTestCase()
-
-
Method Details
-
getInstanceProperties
-
loginAdmin
public void loginAdmin() -
_loginAsUser
-
userWithUsernameAndDisplayName
-
assertAtLoginForm
public void assertAtLoginForm() -
assertAtLoginForm
public void assertAtLoginForm(io.restassured.response.Response response) -
loginWithRestAndRedirectToStartPage
-
loginWithRestEndpoint
protected io.restassured.response.Response loginWithRestEndpoint(String username, String password, boolean rememberMe) Logs in using the rest endpoint, does not navigate to page returned by the redirect endpoint. Consumers should take care to callJWebUnit.beginAt(String)
as this method will put the cookies into the JWebUnit's testing context, but they won't be effective until a beginAt call.- Parameters:
username
- the usernamepassword
- the passwordrememberMe
- the remember me- Returns:
- a RestAssured response, mirroring the response obtained from the server.
-
loginWithRestEndpoint
protected io.restassured.response.Response loginWithRestEndpoint(String username, String password, boolean rememberMe, List<org.apache.http.NameValuePair> queryParams) Logs in using the rest endpoint, does not navigate to page returned by the redirect endpoint. Consumers should take care to callJWebUnit.beginAt(String)
as this method will put the cookies into the JWebUnit's testing context, but they won't be effective until a beginAt call.- Parameters:
username
- the usernamepassword
- the passwordrememberMe
- the remember mequeryParams
- the query parameter- Returns:
- a RestAssured response, mirroring the response obtained from the server.
-
performRequestWithCookieExchange
protected io.restassured.response.Response performRequestWithCookieExchange(com.google.common.base.Function<io.restassured.specification.RequestSpecification, io.restassured.response.Response> requestPerformer) -
_logout
public void _logout() -
assertIsLoggedIn
public void assertIsLoggedIn() -
isLoggedIn
public boolean isLoggedIn() -
isLoggedInAfterRefresh
public boolean isLoggedInAfterRefresh() -
assertIsLoggedOut
public void assertIsLoggedOut() -
getUsersForDirectory
-
getUsersCount
public int getUsersCount(long directoryId) -
intendToModifyLdapData
public void intendToModifyLdapData()Indicate that a test will modify LDAP data. (Not implemented; included so we can start to mark those tests.)- Overrides:
intendToModifyLdapData
in classCrowdWebDriverTest
-
restoreCrowdFromXMLWithoutReloggingIn
-
gotoAddApplication
public void gotoAddApplication() -
gotoCreateDirectory
public void gotoCreateDirectory() -
gotoAddGroup
public void gotoAddGroup() -
gotoViewPrincipal
-
gotoRemovePrincipal
-
gotoViewGroup
-
gotoAddPrincipal
public void gotoAddPrincipal() -
gotoBrowseApplications
public void gotoBrowseApplications() -
gotoBrowsePrincipals
public void gotoBrowsePrincipals() -
gotoBrowsePrincipals
public void gotoBrowsePrincipals(int resultsStart) -
gotoBrowseGroups
public void gotoBrowseGroups() -
gotoBrowseGroups
public void gotoBrowseGroups(int resultsStart) -
gotoBrowseDirectories
public void gotoBrowseDirectories() -
gotoImporters
public void gotoImporters() -
gotoSystemInfo
public void gotoSystemInfo() -
log
- Overrides:
log
in classCrowdWebTestCase
-
setUp
- Overrides:
setUp
in classCrowdWebTestCase
- Throws:
Exception
-
gotoGeneral
public void gotoGeneral() -
gotoLicensing
public void gotoLicensing() -
gotoMailServer
public void gotoMailServer() -
gotoMailTemplate
public void gotoMailTemplate() -
gotoSessionConfig
public void gotoSessionConfig() -
gotoCurrentApplicationSessions
public void gotoCurrentApplicationSessions() -
gotoCurrentPrincipalSessions
public void gotoCurrentPrincipalSessions() -
gotoTrustedProxies
public void gotoTrustedProxies() -
gotoLoggingProfiling
public void gotoLoggingProfiling() -
gotoRestore
public void gotoRestore() -
gotoViewApplication
-
gotoViewApplicationDirectories
-
gotoSAMLConfig
public void gotoSAMLConfig() -
gotoLdapConnectionPool
public void gotoLdapConnectionPool() -
assertPageNotFound
public void assertPageNotFound() -
assertMatchInTableBody
-
assertNoMatchInTableBody
-
assertUserInTable
-
assertUserNotInTable
-
assertUserInTable
-
assertUnescapedKeyNotPresent
-
assertUnescapedKeyPresent
-
disableIPValidation
public void disableIPValidation() -
getUserDetailsTableContents
-
userWithDetails
-
gotoAdministrationPage
public void gotoAdministrationPage() -
getGroupTableContents
-
doBackup
Returns file name of the backup. -
restGet
-
restPost
-
namesOf
-