Class AbstractNotificationsSettingsPage
- java.lang.Object
-
- org.xwiki.test.ui.po.BaseElement
-
- org.xwiki.test.ui.po.BasePage
-
- org.xwiki.test.ui.po.ViewPage
-
- org.xwiki.platform.notifications.test.po.AbstractNotificationsSettingsPage
-
- Direct Known Subclasses:
NotificationsAdministrationPage
,NotificationsUserProfilePage
public abstract class AbstractNotificationsSettingsPage extends ViewPage
Represents a page for notification settings. This kind of page can be seen in user profile or in global administration.- Since:
- 13.2RC1
- Version:
- $Id: 4420f17225ebb52f9767c26788bd391f012301b2 $
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AbstractNotificationsSettingsPage.AutowatchMode
Represents the available autowatch mode values.static class
AbstractNotificationsSettingsPage.EmailDiffType
Represents the available email changes settings values.
-
Field Summary
Fields Modifier and Type Field Description protected org.openqa.selenium.WebElement
notificationCustomFilterPreferencesLivetable
protected org.openqa.selenium.WebElement
notificationSystemFilterPreferencesLivetable
-
Constructor Summary
Constructors Constructor Description AbstractNotificationsSettingsPage()
-
Method Summary
-
Methods inherited from class org.xwiki.test.ui.po.ViewPage
clickBreadcrumbLink, clickWantedLink, clickWantedLink, contentContainsElement, editSection, exists, getBreadcrumb, getBreadcrumbContent, getContent, getLastModifiedText, getPageBackgroundColor, getTitleColor, getTitleFontFamily, getTranslateButton, hasBreadcrumbContent, hasBreadcrumbContent, hasTranslateButton, isInlinePage, openCommentsDocExtraPane, openHistoryDocExtraPane, openInformationDocExtraPane, scrollToTop, useShortcutForDocExtraPane, useShortcutKeyForCommentPane, useShortcutKeyForHistoryPane, useShortcutKeyForInformationPane, waitForDocExtraPaneActive, waitUntilContent
-
Methods inherited from class org.xwiki.test.ui.po.BasePage
canDelete, clickAdminActionsSubMenuEntry, clickEditSubMenuEntry, clickLocale, clickMoreActionsSubMenuEntry, copy, createInlinePage, createPage, delete, deletePage, edit, editClass, editInline, editObjects, editRights, editWiki, editWYSIWYG, getCurrentUser, getDocumentTitle, getDrawerMenu, getEditURL, getErrorContent, getHTMLMetaDataValue, getLocales, getMetaDataValue, getPageTitle, getPageURL, getXWikiMessageContent, hasLeftPanel, hasLoginLink, hasNotificationsMenu, hasRenderingError, isAuthenticated, isForbidden, isNewDocument, isNotificationsMenuOpen, login, logout, register, reloadPage, rename, sendKeys, toggleActionMenu, toggleNotificationsMenu, useShortcutKeyForClassEditing, useShortcutKeyForEditing, useShortcutKeyForInlineEditing, useShortcutKeyForObjectEditing, useShortcutKeyForPageDeletion, useShortcutKeyForPageRenaming, useShortcutKeyForRightsEditing, useShortcutKeyForSourceViewer, useShortcutKeyForWikiEditing, useShortcutKeyForWysiwygEditing, validateWCAG, validateWCAG, validateWCAG, viewChildren, watchDocument, watchSpace, watchWiki
-
Methods inherited from class org.xwiki.test.ui.po.BaseElement
getDriver, getUtil, isElementVisible, setContext, waitForNotificationErrorMessage, waitForNotificationInProgressMessage, waitForNotificationSuccessMessage, waitForNotificationWarningMessage, waitUntilPageIsReady
-
-
-
-
Method Detail
-
waitUntilPreferencesAreLoaded
protected void waitUntilPreferencesAreLoaded()
Ensure to wait until the preferences switches are loaded.
-
initializeApplications
protected void initializeApplications()
Initialize the page with applications informations.
-
getApplicationPreferences
public Map<String,ApplicationPreferences> getApplicationPreferences()
- Returns:
- a map of the preferences for each application
- Since:
- 9.7RC1
-
getApplication
public ApplicationPreferences getApplication(String applicationId) throws Exception
- Parameters:
applicationId
- id of the application- Returns:
- the preferences for the given application
- Throws:
Exception
- if the application cannot be found- Since:
- 9.7RC1
-
getEventType
public EventTypePreferences getEventType(String applicationId, String eventType) throws Exception
- Parameters:
applicationId
- id of the applicationeventType
- name of the event type- Returns:
- the preferences for the given event type of the given application
- Throws:
Exception
- if the event type cannot be found- Since:
- 9.7RC1
-
getApplicationState
public BootstrapSwitch.State getApplicationState(String applicationId, String format) throws Exception
- Parameters:
applicationId
- id of the applicationformat
- the format of the notification- Returns:
- the state of the switch related to given application and format
- Throws:
Exception
- if the application cannot be found- Since:
- 9.7RC1
-
getEventTypeState
public BootstrapSwitch.State getEventTypeState(String applicationId, String eventType, String format) throws Exception
- Parameters:
applicationId
- id of the applicationeventType
- name of the event typeformat
- the format of the notification- Returns:
- the state of the switch related to given event type and format
- Throws:
Exception
- if the event type cannot be found- Since:
- 9.7RC1
-
setApplicationState
public void setApplicationState(String applicationId, String format, BootstrapSwitch.State state) throws Exception
Set the state of the given application for the given format.- Parameters:
applicationId
- id of the applicationformat
- the format of the notificationstate
- the state to set- Throws:
Exception
- if the application is not found- Since:
- 9.7RC1
-
setEventTypeState
public void setEventTypeState(String applicationId, String eventType, String format, BootstrapSwitch.State state) throws Exception
Set the state of the event type for the given format.- Parameters:
applicationId
- id of the applicationeventType
- name of the event typeformat
- the format of the notificationstate
- the state to set- Throws:
Exception
- if the event type cannot be found- Since:
- 9.7RC1
-
disableAllParameters
public void disableAllParameters()
Disable every notification parameters.
-
getNotificationFilterPreferences
@Deprecated public List<NotificationFilterPreference> getNotificationFilterPreferences()
Deprecated.Since 13.2RC1 you should usegetSystemNotificationFilterPreferences()
orgetCustomNotificationFilterPreferences()
.- Returns:
- the notification filter preferences, as they are described in the corresponding livetable
- Since:
- 10.8RC1, 9.11.8
-
getSystemNotificationFilterPreferences
public List<SystemNotificationFilterPreference> getSystemNotificationFilterPreferences()
- Returns:
- the system notification filter preferences.
- Since:
- 13.2RC1
-
getCustomNotificationFilterPreferences
public List<CustomNotificationFilterPreference> getCustomNotificationFilterPreferences()
- Returns:
- the custom notification filter preferences
- Since:
- 13.2RC1
-
getNotificationEmailDiffType
public AbstractNotificationsSettingsPage.EmailDiffType getNotificationEmailDiffType()
- Returns:
- the value of the email details of change.
- Since:
- 13.2RC1
-
setNotificationEmailDiffType
public void setNotificationEmailDiffType(AbstractNotificationsSettingsPage.EmailDiffType value)
Set the email diff type setting.- Parameters:
value
- the diff type to set.- Since:
- 13.2RC1
-
getAutoWatchModeValue
public AbstractNotificationsSettingsPage.AutowatchMode getAutoWatchModeValue()
- Returns:
- the value of the autowatch mode.
- Since:
- 13.2RC1
-
setAutoWatchMode
public void setAutoWatchMode(AbstractNotificationsSettingsPage.AutowatchMode value)
Set the autowatch mode value.- Parameters:
value
- the autowatch mode to set.- Since:
- 13.2RC1
-
clickAddCustomFilter
public CustomNotificationFilterModal clickAddCustomFilter()
Open the modal to add a new custom filter.- Returns:
- the modal to manipulate.
- Since:
- 13.3RC1
-
-