Title: Theory / Important / CS / Programming / Objective-C / test / Earl Grey / Chrome matchers
Tags: automatedNewLineAfterCommaSpace
On every note of this deck, unless a note says otherwise:
Language: Objective-C

Instruction: WindowWithNumber(n)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the n-th window
Library: chrome_test_util

Instruction: MatchInWindowWithNumber(
  n,
  matcher
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher restricted to elements under the n-th window
Library: chrome_test_util

Instruction: MatchInBlockerWindowWithNumber(
  n,
  matcher
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher restricted to elements under the n-th window, when a blocking UI is shown in another window
Library: chrome_test_util

Instruction: ButtonWithAccessibilityLabelId(id)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Section: Matcher for element with accessibility label corresponding to |id| and accessibility trait UIAccessibilityTraitButton.
Library: chrome_test_util

Instruction: ButtonWithAccessibilityLabel(label)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Section: Matcher for element with accessibility label corresponding to |label| and accessibility trait UIAccessibilityTraitButton.
Library: chrome_test_util

Instruction: ButtonWithImage(image_id)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Section: Matcher for element with an image corresponding to |image_id| and accessibility trait UIAccessibilityTraitButton.
Library: chrome_test_util

Instruction: ImageViewWithImage(image_id)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for element with an image corresponding to |image_id|.
Library: chrome_test_util

Instruction: ImageViewWithImageNamed(imageName)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for element with an image defined by its name in the main bundle.
Library: chrome_test_util

Instruction: StaticTextWithAccessibilityLabelId(id)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for element with accessibility label corresponding to |id| and accessibility trait UIAccessibilityTraitStaticText.
Library: chrome_test_util

Instruction: StaticTextWithAccessibilityLabel(label)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for element with accessibility label corresponding to |label| and accessibility trait UIAccessibilityTraitStaticText.
Library: chrome_test_util

Instruction: ContainsPartialText(text)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for a text element (label, field, etc) whose text contains |text| as a substring. (contrast with grey_text() which tests for a complete string match).
Library: chrome_test_util

Instruction: HeaderWithAccessibilityLabelId(message_id)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for element with accessibility label corresponding to |message_id| and accessibility trait UIAccessibilityTraitHeader.
Library: chrome_test_util

Instruction: HeaderWithAccessibilityLabel(label)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for element with accessibility label corresponding to |label| and accessibility trait UIAccessibilityTraitHeader.
Library: chrome_test_util

Instruction: NavigationBarTitleWithAccessibilityLabelId(label_id)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for navigation bar title element with accessibility label corresponding to |label_id|.
Library: chrome_test_util

Instruction: TextFieldForCellWithLabelId(message_id)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for text field of a cell with |message_id|.
Library: chrome_test_util

Instruction: IconViewForCellWithLabelId(
  message_id,
  icon_type
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for icon view of a cell with |message_id|.
Library: chrome_test_util

Instruction: PrimaryToolbar()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the primary toolbar.
Library: chrome_test_util

Instruction: CancelButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for a cancel button
Library: chrome_test_util

Instruction: NavigationBarCancelButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for an enabled cancel button in a navigation bar.
Library: chrome_test_util

Instruction: CloseButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for a close button
Library: chrome_test_util

Instruction: CloseTabMenuButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for close tab menu button.
Library: chrome_test_util

Instruction: ForwardButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the navigate forward button.
Library: chrome_test_util

Instruction: BackButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the navigate backward button.
Library: chrome_test_util

Instruction: ReloadButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the reload button.
Library: chrome_test_util

Instruction: StopButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the stop loading button.
Library: chrome_test_util

Instruction: Omnibox()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the omnibox
Library: chrome_test_util

Instruction: DefocusedLocationView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the location view.
Library: chrome_test_util

Instruction: PageSecurityInfoButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the page security info button.
Library: chrome_test_util

Instruction: PageSecurityInfoIndicator()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: a matcher for the page security info indicator.
Library: chrome_test_util

Instruction: OmniboxText(text)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for omnibox containing |text|. Performs an exact match of the omnibox contents.
Library: chrome_test_util

Instruction: OmniboxContainingText(text)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for |text| being a substring of the text in the omnibox.
Library: chrome_test_util

Instruction: LocationViewContainingText(text)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for |text| being a substring of the text in the location view.
Library: chrome_test_util

Instruction: ToolsMenuButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for Tools menu button.
Library: chrome_test_util

Instruction: ShareButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the share menu button
Library: chrome_test_util

Instruction: TabShareButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the tab Share button (either in the omnibox or toolbar).
Library: chrome_test_util

Instruction: ShowTabsButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the show tabs button
Library: chrome_test_util

Instruction: AddToReadingListButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for Add to reading list button.
Library: chrome_test_util

Instruction: AddToBookmarksButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for Add to bookmarks button.
Library: chrome_test_util

Instruction: TableViewSwitchCell(
  accessibility_identifier,
  is_toggled_on[,
  is_enabled]
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for TableViewSwitchCell.
Library: chrome_test_util

Instruction: SyncSwitchCell(
  accessibility_label,
  is_toggled_on
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for LegacySyncSwitchCell.
Library: chrome_test_util

Instruction: OpenLinkInNewTabButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Open in New Tab option in the context menu when long pressing a link.
Library: chrome_test_util

Instruction: OpenLinkInIncognitoButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Open in Incognito option in the context menu when long pressing a link.
Library: chrome_test_util

Instruction: OpenLinkInNewWindowButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Open in New Window option in the context menu when long pressing a link.
Library: chrome_test_util

Instruction: NavigationBarDoneButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the done button on the navigation bar.
Library: chrome_test_util

Instruction: BookmarksNavigationBarDoneButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the done button on the Bookmarks navigation bar.
Library: chrome_test_util

Instruction: BookmarksNavigationBarBackButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the back button on the Bookmarks navigation bar.
Library: chrome_test_util

Instruction: AddAccountButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the add account accounts button.
Library: chrome_test_util

Instruction: SignOutAccountsButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the sign out accounts button.
Library: chrome_test_util

Instruction: ClearBrowsingDataCell()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the Clear Browsing Data cell on the Privacy screen.
Library: chrome_test_util

Instruction: ClearBrowsingDataButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the clear browsing data button on the clear browsing data panel.
Library: chrome_test_util

Instruction: ClearBrowsingDataView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the clear browsing data view.
Library: chrome_test_util

Instruction: ConfirmClearBrowsingDataButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the clear browsing data action sheet item.
Library: chrome_test_util

Instruction: SettingsMenuButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the settings button in the tools menu.
Library: chrome_test_util

Instruction: SettingsDoneButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the "Done" button in the settings' navigation bar.
Library: chrome_test_util

Instruction: AutofillCreditCardEditTableView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the Autofill Credit Card "Payment Methods" edit view.
Library: chrome_test_util

Instruction: AutofillCreditCardTableView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Autofill Credit Card "Payment Methods" view in the settings menu.
Library: chrome_test_util

Instruction: AddressesAndMoreButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the "Addresses and More" button in the settings menu.
Library: chrome_test_util

Instruction: PaymentMethodsButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the "Payment Methods" button in the settings menu.
Library: chrome_test_util

Instruction: LanguagesButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the "Languages" button in the settings menu.
Library: chrome_test_util

Instruction: AddCreditCardView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Returns matcher for the "Add Credit Card" view in the Settings menu.
Library: chrome_test_util

Instruction: AddPaymentMethodButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the "Add Payment Method" button in the Settings Payment Methods view.
Library: chrome_test_util

Instruction: AddCreditCardButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: matcher for the "Add" credit card button in the Payment Methods add credit card view.
Library: chrome_test_util

Instruction: AddCreditCardCancelButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the "Cancel" button in the Payment Methods add credit card view.
Library: chrome_test_util

Instruction: ToolsMenuView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the tools menu table view.
Library: chrome_test_util

Instruction: OKButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the OK button.
Library: chrome_test_util

Instruction: PrimarySignInButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the primary button in the sign-in promo view
Extra: This is "Sign in into Chrome" button for a cold state,
  or "Continue as John Doe" for a warm state.
Library: chrome_test_util

Instruction: SecondarySignInButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the secondary button in the sign-in promo view
Extra: This is "Not johndoe@example.com" button.
Library: chrome_test_util

Instruction: SettingsAccountButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the button for the currently signed in account in the settings menu.
Library: chrome_test_util

Instruction: SettingsAccountsCollectionView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the accounts collection view.
Library: chrome_test_util

Instruction: SettingsImportDataImportButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Import Data cell in switch sync account view.
Library: chrome_test_util

Instruction: SettingsImportDataKeepSeparateButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Keep Data Separate cell in switch sync account view.
Library: chrome_test_util

Instruction: SettingsImportDataContinueButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Keep Data Separate cell in switch sync account view.
Library: chrome_test_util

Instruction: SettingsPrivacyTableView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the privacy settings table view.
Library: chrome_test_util

Instruction: ContentSettingsButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Content Settings button on the main Settings screen.
Library: chrome_test_util

Instruction: GoogleServicesSettingsButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Google Services Settings button on the main Settings
// screen.
Library: chrome_test_util

Instruction: ManageSyncSettingsButton()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Manage Sync Settings button on the main Settings screen.
Library: chrome_test_util

Instruction: GoogleServicesSettingsView()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_matchers.h
Context: chrome
Returns: Matcher for the Google Services Settings view.
Library: chrome_test_util

Instruction: Matcher for the back button on a settings menu
Returns: SettingsMenuBackButton()

Instruction: Matcher for the back button on a settings menu in given window number
Returns: SettingsMenuBackButton(int window_number)

Instruction: Matcher for the Privacy cell on the main Settings screen
Returns: SettingsMenuPrivacyButton()

Instruction: Matcher for the Save passwords cell on the main Settings screen
Returns: SettingsMenuPasswordsButton()

Instruction: Matcher for the payment request collection view
Returns: PaymentRequestView()

Instruction: Matcher for the error confirmation view for payment request
Returns: PaymentRequestErrorView()

Instruction: Matcher for the voice search button on the main Settings screen
Returns: VoiceSearchButton()

Instruction: Matcher for the voice search button on the omnibox input accessory
Returns: VoiceSearchInputAccessoryButton()

Instruction: Matcher for the settings main menu view
Returns: SettingsCollectionView()

Instruction: Matcher for the clear browsing history cell on the clear browsing data panel
Returns: ClearBrowsingHistoryButton()

Instruction: Matcher for the clear cookies cell on the clear browsing data panel
Returns: ClearCookiesButton()

Instruction: Matcher for the clear cache cell on the clear browsing data panel
Returns: ClearCacheButton()

Instruction: Matcher for the clear saved passwords cell on the clear browsing data panel
Returns: ClearSavedPasswordsButton()

Instruction: Matcher for the clear saved passwords cell on the clear browsing data panel
Returns: ClearAutofillButton()

Instruction: Matcher for the collection view of content suggestion
Returns: ContentSuggestionsCollectionView()

Instruction: Matcher for the collection view of the NTP
Returns: NTPCollectionView()

Instruction: Matcher for the NTP view when the user is in incognito mode
Returns: NTPIncognitoView()

Instruction: Matcher for the NTP Feed menu button which enables the feed
Returns: NTPFeedMenuEnableButton()

Instruction: Matcher for the NTP Feed menu button which disables the feed
Returns: NTPFeedMenuDisableButton()

Instruction: Matcher for the warning message while filling in payment requests
Returns: WarningMessageView()

Instruction: Matcher for the payment picker cell
Returns: PaymentRequestPickerRow()

Instruction: Matcher for the payment request search bar
Returns: PaymentRequestPickerSearchBar()

Instruction: Matcher for the New Window button on the Tools menu
Returns: OpenNewWindowMenuButton()

Instruction: Matcher for the reading list on the Tools menu
Returns: ReadingListMenuButton()

Instruction: Matcher for the bookmarks button on the Tools menu
Returns: BookmarksMenuButton()

Instruction: Matcher for the recent tabs button on the Tools menu
Returns: RecentTabsMenuButton()

Instruction: Matcher for the system selection callout
Returns: SystemSelectionCallout()

Instruction: Matcher for the Link to text button in the edit menu
Returns: SystemSelectionCalloutLinkToTextButton()

Instruction: Matcher for the copy button on the system selection callout
Returns: SystemSelectionCalloutCopyButton()

Instruction: Matcher for the system selection callout overflow button to show more menu items
Returns: SystemSelectionCalloutOverflowButton()

Instruction: Matcher for a Copy button, such as the one in the Activity View. This matcher is very broad and will look for any button with a matching string. Only the iOS 13 Activity View is reachable by EarlGrey
Returns: CopyActivityButton()

Instruction: Matcher for the Copy Link option in the updated context menus when long pressing on a link
Returns: CopyLinkButton()

Instruction: Matcher for the Edit option on the context menus
Returns: EditButton()

Instruction: Matcher for the Move option on the updated context menus
Returns: MoveButton()

Instruction: Matcher for the Mark as Read option on the Reading List's context menus
Returns: ReadingListMarkAsReadButton()

Instruction: Matcher for the Mark as Unread option on the Reading List's context menus
Returns: ReadingListMarkAsUnreadButton()

Instruction: Matcher for the Delete option on the updated context menus
Returns: DeleteButton()

Instruction: Matcher for the Copy item on the old-style context menu
Returns: ContextMenuCopyButton()

Instruction: Matcher for defoucesed omnibox on a new tab
Returns: NewTabPageOmnibox()

Instruction: Matcher for a fake omnibox on a new tab page
Returns: FakeOmnibox()

Instruction: Matcher for a header label of the Discover feed
Returns: DiscoverHeaderLabel()

Instruction: Matcher for a logo on a new tab page
Returns: NTPLogo()

Instruction: Matcher for the current WebView
Returns: WebViewMatcher()

Instruction: Matcher for the current WebState's scroll view
Returns: WebStateScrollViewMatcher()

Instruction: Matcher for the current WebState's scroll view in the given |window_number|
Returns: WebStateScrollViewMatcherInWindowWithNumber(int window_number)

Instruction: Matcher for the Clear Browsing Data button in the History UI
Returns: HistoryClearBrowsingDataButton()

Instruction: Matcher for "Open In..." button
Returns: OpenInButton()

Instruction: Matcher for the cell at |index| in the tab grid
Returns: TabGridCellAtIndex(unsigned int index)

Instruction: Matcher for the button that closes the tab grid
Returns: TabGridDoneButton()

Instruction: Matcher for the button that closes all the tabs in the tab grid
Returns: TabGridCloseAllButton()

Instruction: Matcher for the button that reverts the close all tabs action in the tab grid
Returns: TabGridUndoCloseAllButton()

Instruction: Matcher for the cell that opens History in Recent Tabs
Returns: TabGridSelectShowHistoryCell()

Instruction: Matcher for the regular tabs empty state view
Returns: TabGridRegularTabsEmptyStateView()

Instruction: Matcher for the button that creates new non incognito tabs from within the tab grid
Returns: TabGridNewTabButton()

Instruction: Matcher for the button that creates new incognito tabs from within the tab grid
Returns: TabGridNewIncognitoTabButton()

Instruction: Matcher for the button to go to the non incognito panel in the tab grid
Returns: TabGridOpenTabsPanelButton()

Instruction: Matcher for the button to go to the incognito panel in the tab grid
Returns: TabGridIncognitoTabsPanelButton()

Instruction: Matcher for the button to go to the other devices panel in the tab grid
Returns: TabGridOtherDevicesPanelButton()

Instruction: Matcher for the tab grid background
Returns: TabGridBackground()

Instruction: Matcher for the regular tab grid
Returns: RegularTabGrid()

Instruction: Matcher for the incognito tab grid
Returns: IncognitoTabGrid()

Instruction: Matcher for the button to close the cell at |index| in the tab grid
Returns: TabGridCloseButtonForCellAtIndex(unsigned int index)

Instruction: Matcher for the password settings collection view
Returns: SettingsPasswordMatcher()

Instruction: Matcher for the search bar in password settings
Returns: SettingsPasswordSearchMatcher()

Instruction: Matcher for the profiles settings collection view
Returns: SettingsProfileMatcher()

Instruction: Matcher for the credit card settings collection view
Returns: SettingsCreditCardMatcher()

Instruction: Matcher for the delete button at the bottom of settings collection views
Returns: SettingsBottomToolbarDeleteButton()

Instruction: Matcher for the search engine button in the main settings view
Returns: SettingsSearchEngineButton()

Instruction: Matcher for an autofill suggestion view
Returns: AutofillSuggestionViewMatcher()

Instruction: Matcher to test whether the element is a scroll view with a content smaller than the scroll view bounds
Returns: ContentViewSmallerThanScrollView()

Instruction: Matcher for a history entry with |url| and |title|
Returns: HistoryEntry(const std::string& url, const std::string& title)

Instruction: Matcher to the add button in the toolbar in the settings view
Returns: SettingsToolbarAddButton()

Instruction: Matcher for the scroll view in keyboard accessory bar
Returns: ManualFallbackFormSuggestionViewMatcher()

Instruction: Matcher for the keyboard icon in the keyboard accessory bar
Returns: ManualFallbackKeyboardIconMatcher()

Instruction: Matcher for the password icon in the keyboard accessory bar
Returns: ManualFallbackPasswordIconMatcher()

Instruction: Matcher for the password table view in manual fallback
Returns: ManualFallbackPasswordTableViewMatcher()

Instruction: Matcher for the password search bar in manual fallback
Returns: ManualFallbackPasswordSearchBarMatcher()

Instruction: Matcher for the button to open password settings in manual fallback
Returns: ManualFallbackManagePasswordsMatcher()

Instruction: Matcher for the button to open all passwords in manual fallback
Returns: ManualFallbackOtherPasswordsMatcher()

Instruction: Matcher for the button to dismiss all passwords in manual fallback
Returns: ManualFallbackOtherPasswordsDismissMatcher()

Instruction: Matcher for the a password in the manual fallback list
Returns: ManualFallbackPasswordButtonMatcher()

Instruction: Matcher for the PasswordTableView window
Returns: ManualFallbackPasswordTableViewWindowMatcher()

Instruction: Matcher for the profiles icon in the keyboard accessory bar
Returns: ManualFallbackProfilesIconMatcher()

Instruction: Matcher for the profiles table view in manual fallback
Returns: ManualFallbackProfilesTableViewMatcher()

Instruction: Matcher for the button to open profile settings in manual fallback
Returns: ManualFallbackManageProfilesMatcher()

Instruction: Matcher for the ProfileTableView window
Returns: ManualFallbackProfileTableViewWindowMatcher()

Instruction: Matcher for the credit card icon in the keyboard accessory bar
Returns: ManualFallbackCreditCardIconMatcher()

Instruction: Matcher for the credit card table view in manual fallback
Returns: ManualFallbackCreditCardTableViewMatcher()

Instruction: Matcher for the button to open password settings in manual fallback
Returns: ManualFallbackManageCreditCardsMatcher()

Instruction: Matcher for the button to add credit cards settings in manual fallback
Returns: ManualFallbackAddCreditCardsMatcher()

Instruction: Matcher for the CreditCardTableView window
Returns: ManualFallbackCreditCardTableViewWindowMatcher()

Instruction: Matcher for the iOS 13+ Activity View header
Returns: ActivityViewHeader(NSString* url_host, NSString* page_title)

Instruction: Matcher for the button to trigger password generation on manual fallback
Returns: ManualFallbackSuggestPasswordMatcher()

Instruction: Matcher for the button to accept the generated password
Returns: UseSuggestedPasswordMatcher()

Instruction: Matcher for the button to open the context menu for edit actions
Returns: TabGridEditButton()

Instruction: Matcher for the context menu button to close all tabs
Returns: TabGridEditMenuCloseAllButton()

Instruction: Matcher for the context menu button to enter the tab grid tab selection mode
Returns: TabGridSelectTabsMenuButton()

Instruction: Matcher for the button to act on the selected tabs
Returns: TabGridEditAddToButton()

Instruction: Matcher for the button to close the selected tabs
Returns: TabGridEditCloseTabsButton()

Instruction: Matcher for the button to select all tabs
Returns: TabGridEditSelectAllButton()

Instruction: Matcher for the button to share tabs
Returns: TabGridEditShareButton()

Typ: ChromeActionsAppInterface
Meaning: Helper class to return actions for EG tests.  These helpers are compiled into the app binary and can be called from either app or test code.
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
Language: Objective-C
Context: chrome

Instruction: [ChromeActionsAppInterface
  longPressElement:selector
  triggerContextMenu:yesOrNo
]
chrome_test_util::LongPressElementForContextMenu(
  selector,
  triggers_context_menu
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to longpress on the element selected by |selector| in the Chrome's webview
Context: chrome

Instruction: [ChromeActionsAppInterface
  scrollElementToVisible:selector
]
chrome_test_util::scrollElementToVisible(
  selector
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: scroll a web element described by the given |selector| to visible on the current web state.
Context: chrome

Instruction: [ChromeActionsAppInterface
  turnTableViewSwitchOn:on
]
chrome_test_util::TurnTableViewSwitchon(on)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to turn the switch of a TableViewSwitchCell to the given |on| state.
Context: chrome

Instruction: [ChromeActionsAppInterface
  turnSyncSwitchOn:on
]
chrome_test_util::TurnSyncSwitchOn(on)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to turn the switch of a SyncSwitchCell to the given |on| state.
Context: chrome

Instruction: [ChromeActionsAppInterface
  tapWebElement:selector
]
chrome_test_util::TapWebElement(selector)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to tap a web element described by the given |selector| on the current web state.
Context: chrome

Instruction: [ChromeActionsAppInterface
  scrollToTop
]
chrome_test_util::ScrollToTop()
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to scroll to top of a collection.
Context: chrome
Extra: On iOS 13 the settings menu appears as a card that can be dismissed with a downward swipe, for this reason we need to swipe up programatically to avoid dismissing the VC.

Instruction: [ChromeActionsAppInterface
  tapAtPointAtxOriginStartPercentage:x
  yOriginStartPercentage:y
]
chrome_test_util::TapAtPointPercentage(
  x,
  y
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions_app_interface.h
https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to tap an element at the given xOriginStartPercentage as a percentage of the total width and yOriginStartPercentage as a percentage of the total height. Percentages are between 0 and 1, where 1 is 100%.
Context: chrome

Instruction: TapWebElementWithId(
  element_id
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to tap a web element with id equal to |element_id| on the current web state.
Context: chrome

Instruction: TapWebElementWithIdInFrame(
  element_id,
  frame_index
)
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_actions.h
Effect: Action to tap a web element in iframe with the given |element_id| on the current web state. iframe is an immediate child of the main frame with the given index. The action fails if target iframe has a different origin from the main frame.
Context: chrome

Typ: ChromeEarlGreyAppInterface
Meaning: the app-side implementation for helpers that primarily work via direct model access. These helpers are compiled into the app binary and can be called from either app or test code.
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Language: Objective-C
Context: chrome

Instruction: ChromeEarlGreyAppInterface.isRTL
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether curent interface language use RTL layout

Instruction: [ChromeEarlGreyAppInterface clearBrowsingHistory]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears browsing history and waits for history to finish clearing before returning.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface clearAllWebStateBrowsingData]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears all web state browsing data and waits to finish clearing before returning.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface browsingHistoryEntryCountWithError:errorPointer]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: number of entries in the history database. -1 in case of error

Instruction: [ChromeEarlGreyAppInterface navigationBackListItemsCount]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears browsing cache.
Context: chrome
Returns: Error, if any

Instruction: [ChromeEarlGreyAppInterface
  startLoadingURL:spec
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Loads the URL |spec| in the current WebState with transition type ui::PAGE_TRANSITION_TYPED and returns without waiting for the page to load.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  waitForWindowIDInjectionIfNeeded
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: If the current WebState is HTML content, will wait until the window ID is injected.
Context: chrome
Returns: Whether injection is successful or if the WebState is not HTML content.

Instruction: [ChromeEarlGreyAppInterface
  isLoading
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: YES if the current WebState is loading.

Instruction: [ChromeEarlGreyAppInterface
  startReloading
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Reloads the page without waiting for the page to load.

Instruction: [ChromeEarlGreyAppInterface
  guideWithName:name
  view:view]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: He NamedGuide with the given |name|, if one is attached to |view| or one of |view|'s ancestors. If no guide is found, returns nil.

Instruction: [ChromeEarlGreyAppInterface
  openURLFromExternalApp:url
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Loads |URL| as if it was opened from an external application.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  dismissSettings
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Programmatically dismisses settings screen.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  selectTabAtIndex:index
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Selects tab with given index in current mode (incognito or main (non-incognito)).
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  closeTabAtIndex:index
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Closes tab with given index in current mode (incognito or main (non-incognito)).
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  isIcognitoMode
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Whether browser is in incognito mode
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  (main|incognito)TabCount
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The number of open (  non-|)incognito tabs

Instruction: [ChromeEarlGreyAppInterface
  browserCount
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The number of open browsers

Instruction: [ChromeEarlGreyAppInterface
  simulateTabsBackgrounding
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Simulates a backgrounding.
Context: chrome
Returns: The error if any

Instruction: [ChromeEarlGreyAppInterface
  saveSessionImmediately
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Persists the current list of tabs to disk immediately.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  evictedMainTabAccount
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the number of main (non-incognito) tabs currently evicted

Instruction: [ChromeEarlGreyAppInterface
  evictedOtherBrowserTabs
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Evicts the tabs associated with the non-current browser mode.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  setCurrentTabsToBeColdStartTabs
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Sets the normal tabs as 'cold start' tabs
If not succeed returns an NSError indicating  why the operation failed, otherwise nil.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  resetTabUsageRecorder
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Resets the tab usage recorder on current mode.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  openNewTab
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Opens a new tab and return immediatly
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  simulateExternalAppURLOpening
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Simulates opening http://www.example.com/ from another application.
Context: chrome
Returns: Returns the opened URL.

Instruction: [ChromeEarlGreyAppInterface
  simulateExternalAppURLOpeningWithURL:URL
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Simulates opening URL from another application.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  simulateAddAccountFromWeb
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Simulates opening the add account sign-in flow from the web.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  closeCurrentTab
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: closeCurrentTab
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  openNewIncognitoTab
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Open a new incognito tab and does not wait for animations to complete
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  closeAllTabsInCurrentMode
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Closes all tabs in the current mode (incognito or normal), and does not wait  for the UI to complete. If current mode is Incognito, mode will be switched normal after closing all tabs.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  closeAll(Normal|Incognito)Tabs
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Closes all (non-|)incognito tabs.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  startGoing(Back|Forward)
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Navigates (back|forward) to the (previous|next) page without waiting for the page to load.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  currentTabTitle
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: title of the current selected tab.

Instruction: [ChromeEarlGreyAppInterface
  nextTabTitle
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: title of the tab after the selected one.
Assuming: this tab exists

Instruction: [ChromeEarlGreyAppInterface
  nextTabId
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: a unique identifier for the next Tab.
Assuming: this tab exists

Instruction: [ChromeEarlGreyAppInterface
  currentTabId
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: a unique identifier for the current Tab.

Instruction: [ChromeEarlGreyAppInterface
  indexOfActiveNormalTab
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the index of active tab in normal mode.

Instruction: [ChromeEarlGreyAppInterface
  screenPositionOfScreenWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: screen position of the given |windowNumber|

Instruction: [ChromeEarlGreyAppInterface
  windowCount
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The number of windows, including background and disconnected or archived windows.

Instruction: [ChromeEarlGreyAppInterface
  foregroundWindowCount
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The number of foreground windows

Instruction: [ChromeEarlGreyAppInterface
  closeAllExtraWindows
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Closes all but one window, including all non-foreground windows.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  openNewWindow
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Open a new window.
Context: chrome
Returns: error if multiwindow is not supported

Instruction: [ChromeEarlGreyAppInterface
  openNewTabInWindowWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Opens a new tab in window with given number, and does not wait for animations to complete.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  closeWindowWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Close the window with given number
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  changeWindowWithNumber:windowNumber
  toNewNumber:newWindowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Renumbers given window with current number to new number.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  startLoadingURL:spec
  inWindowWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Loads the URL |spec| in the current WebState in window with given number with transition type ui::PAGE_TRANSITION_TYPED and returns without waiting for the page to load.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  isLoadinginWindowWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: whether the current WebState in window with given number is loading.

Instruction: [ChromeEarlGreyAppInterface
  waitForWindowIDInjectionIfNeededInWindowWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: whether the injection is successful or whether the webstate is not HTML content
Time complexity: if the current WebState in window with given number is HTML content, wait until the window ID is injected.

Instruction: [ChromeEarlGreyAppInterface
  webStateContainsText:text
  inWindowWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether current webstate in windowNumber contains |text|

Instruction: [ChromeEarlGreyAppInterface
  (main|incognito)TabCountInWindowWithNumber:windowNumber
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the number of open (non-|)incognito tabs, in window with given number

Instruction: [ChromeEarlGreyAppInterface
  tapWebStateElementInIFrameWithID:elementID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Attempts to tap the element with |element_id| within window.frames[0] of the current WebState using a JavaScript click() event.
Context: chrome
Returns: error if any
Extra: This only works on same-origin iframes

Instruction: [ChromeEarlGreyAppInterface
  tapWebStateElementInIFrameWithID:elementID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Taps html element with |elementID| in the current web state.
Context: chrome
Returns: error if any

Instruction: [ChromeEarlGreyAppInterface
  waitForWebStateContainingElement:selector
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for the current web state to contain an element matching |selector|.
Context: chrome
Returns: error if any

Instruction: [ChromeEarlGreyAppInterface
  waitForWebStateNotContainingElement:selector
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for the current web state to no longer contain an element matching |selector|
Context: chrome
Returns: error if any

Instruction: [ChromeEarlGreyAppInterface
  waitForWebStateContainingTextInIFrame:text
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for the current web state's frames to contain |text|.
Context: chrome
Returns: error if any

Instruction: [ChromeEarlGreyAppInterface
  submitWebStateFormWithID:formID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Attempts to submit form with |formID| in the current WebState.
Context: chrome
Returns: error if any

Instruction: [ChromeEarlGreyAppInterface
  webStateContainsElement:selector
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: whether the current WebState contains an element matching |selector|.

Instruction: [ChromeEarlGreyAppInterface
  webStateContainsText:text
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: whether the current WebState contains |text|.

Instruction: [ChromeEarlGreyAppInterface
  waitForWebStateContainingLoadedImage:imageID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for the current WebState to contain loaded image with |imageID|. When loaded, the image element will have the same size as actual image.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  waitForWebStateContainingBlockedImage:imageID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for the current WebState to contain a blocked image with |imageID|. When blocked, the image element will be smaller than the actual image size.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  waitForWebStateZoomScale:scale
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for the web state's scroll view zoom scale to be suitably close (within 0.05) of the expected scale.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  signOutAndClearIdentities
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Signs the user out from Chrome and then starts clearing the identities.
Context: chrome
Extra: // Note: This method does not wait for identities to be cleared from the
// keychain. To wait for this operation to finish, please use an GREYCondition
// and wait for +hasIdentities to return NO.

Instruction: [ChromeEarlGreyAppInterface
  hasIdentities
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether there is at at least identity in the ChromeIdentityService.

Instruction: [ChromeEarlGreyAppInterface
  webStateVisibleURL
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: current WebState's VisibleURL.

Instruction: [ChromeEarlGreyAppInterface
  webStateLastCommittedURL
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the current WebState's last committed URL.

Instruction: [ChromeEarlGreyAppInterface
  purgeCachedWebViewPages
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Purges cached web view pages in the current web state, so the next time back navigation will not use a cached page. Browsers don't have to use a fresh version for back/forward navigation for HTTP pages and may serve a version from the cache even if the Cache-Control response header says otherwise
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  isRestoreSessionInProgress
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether the current webstate's navigation manager is currently restoring session state

Instruction: [ChromeEarlGreyAppInterface
  webStateWebViewUsesContentInset
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether the current WebState's web view uses the content inset to correctly align the top of the content with the bottom of the top bar.

Instruction: [ChromeEarlGreyAppInterface
  webStateWebViewSize
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The size of the current WebState's web view

Instruction: [ChromeEarlGreyAppInterface
  stopAllWebStatesLoading
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Stops any pending navigations in all WebStates which are loading.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  waitForBookmarksToFinishinLoading
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for the bookmark internal state to be done loading.
Context: chrome
Returns: Error, if any

Instruction: [ChromeEarlGreyAppInterface
  clearBookmarks
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears bookmarks.
Context: chrome
Returns: Error, if any

Instruction: [ChromeEarlGreyAppInterface
  displayTitleForUrl:url
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The title string to be used for a page with |URL| if that page doesn't specify a title.

Instruction: [ChromeEarlGreyAppInterface
  clearSyncServerData
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears fake sync server data if the server is running.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  signInWithoutSyncWithIdentity:identity
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Signs in with |identity| without sync consent.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  startSync
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Starts the sync server.
Context: chrome
Assuming: The server should not be running when calling this

Instruction: [ChromeEarlGreyAppInterface
  stopSync
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Stop the sync server.
Context: chrome
Assuming: The server should be running when calling this

Instruction: [ChromeEarlGreyAppInterface
  waitForSyncInitialized:isInitialized
  syncTimeout:timeout
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for sync to be initialized or not.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  syncCacheGUID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the current sync cache GUID
Assuming: The server should be running when calling this

Instruction: [ChromeEarlGreyAppInterface
  waitForSyncInvalidationFields
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Waits for sync invalidation field presence in the DeviceInfo data type on the server.
Context: chrome
Returns: Error if any

Instruction: [ChromeEarlGreyAppInterface
  isFakeSyncServerSetUp
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether or not the fake sync server has been setup.

Instruction: [ChromeEarlGreyAppInterface
  setUpFakeSyncServer
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Sets up a fake sync server to be used by the SyncServiceImpl.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  tearDownFakeSyncServer
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Tears down the fake sync server used by the SyncServiceImpl and restores the real one.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  numberOfSyncEntitiesWithType:type
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the number of entities of the given |type|.

Instruction: [ChromeEarlGreyAppInterface
  addFakeSyncServerBookmarkWithURL:URL
  title:title
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Injects a bookmark into the fake sync server with |URL| and |title|.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  addFakeSyncServerBookmarkWithURL:URL
  title:title
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Injects a legacy bookmark into the fake sync server.
Context: chrome
Extra: The legacy bookmark means 2015 and earlier, prior to the adoption of GUIDs for originator client item ID.

Instruction: [ChromeEarlGreyAppInterface
  addFakeSyncServerLegacyBookmarkWithURL:URL
  title:title
  originator_client_item_id:id
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Injects a legacy bookmark into the fake sync server.
Context: chrome
Extra: The legacy bookmark means 2015 and earlier, prior to the adoption of GUIDs for originator client item ID.

Instruction: [ChromeEarlGreyAppInterface
  addFakeSyncServerTypedURL:URL
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Injects typed URL to sync FakeServer.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  addHistoryServiceTypedURL:URL
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Adds typed URL into HistoryService.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  deleteHistoryServiceTypedURL:URL
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Deletes typed URL from HistoryService.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  isTypedURL:spec
  presentOnClient:expectPresent
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether url |spec| is present or not present in HistoryService (depending on |expectPresent)

Instruction: [ChromeEarlGreyAppInterface
  triggerSyncCycleForType:type
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Triggers a sync cycle for a |type|.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  addUserDemographicsToSyncServerWithBirthYear:rawBirthYear
  gender:gender
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Injects user demographics into the fake sync server.
Context: chrome
Extra: |rawBirthYear| is the
// true birth year, pre-noise, and the gender corresponds to the proto enum
// UserDemographicsProto::Gender.

Instruction: [ChromeEarlGreyAppInterface
  clearAutofillProfileWithGUID:GUID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears the autofill profile for the given |GUID|.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  addAutofillProfileToFakeSyncServerWithGUID:GUID
  autofillProfileName:fullName;
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Injects an autofill profile into the fake sync server with |GUID| and |full_name|.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  deleteAutofillProfileFromFakeSyncServerWithGUID:GUID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Deletes an autofill profile from the fake sync server with |GUID|, if it exists. If it doesn't exist, nothing is done.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  verifySessionsOnSyncServerWithSpecs:specs
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Verifies the sessions hierarchy on the Sync FakeServer.
Context: chrome
Extra: |specs| is the collection of URLs that are to be expected for a single window. On failure, returns a NSError describing the failure. See the SessionsHierarchy class for documentation regarding the verification.

Instruction: [ChromeEarlGreyAppInterface
  verifyNumberOfSyncEntitiesWithType:type
                                          name:name
                                         count:count
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Verifies that |count| entities of the given |type| and |name| exist on the sync FakeServer
Context: chrome
Extra: Folders are not included in this count. Returns NSError if there is a failure or if the count does not match.

Instruction: [ChromeEarlGreyAppInterface
  addBookmarkWithSyncPassphrase:syncPassphrase
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Adds a bookmark with a sync passphrase. The sync server will need the sync passphrase to start.
Context: chrome
Extra: Folders are not included in this count. Returns NSError if there is a failure or if the count does not match.

Instruction: [ChromeEarlGreyAppInterface
  executeJavascript:javascript
  error:error
]
TODO:Check. Also check [ChromeEarlGreyAppInterface
  executeJavascript:javascript]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Executes JavaScript on current WebState, and waits for either the completion or timeout
Context: chrome
Extra: If execution does not complete within a timeout or JavaScript exception is thrown, returns an NSError indicating why the operation failed, otherwise returns object representing execution result.

Instruction: [ChromeEarlGreyAppInterface
  mobileUserAgentString
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the user agent that should be used for the mobile version.

Instruction: [ChromeEarlGreyAppInterface
  verifyAccessibilityForCurrentScreen
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Error if not all interactive elements on screen (or at least one of their descendants) are accessible

Instruction: [ChromeEarlGreyAppInterface
  isBlockNewTabPagePendingLoadEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether BlockNewTabPagePendingLoad feature is enabled.

Instruction: [ChromeEarlGreyAppInterface
  isVariationEnabled:variationID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether |variationID| feature is enabled.

Instruction: [ChromeEarlGreyAppInterface
  isTriggerVariationEnabled:variationID
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether a variation triggering server-side behavior is enabled.

Instruction: [ChromeEarlGreyAppInterface
  isAddCredentialsInSettingsEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether |kSupportForAddPasswordsInSettings| is enabled.

Instruction: [ChromeEarlGreyAppInterface
  isUKMEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether UKM feature is enabled

Instruction: [ChromeEarlGreyAppInterface
  isSynthesizedRestoreSessionEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether kSynthesizedRestoreSessionEnabled feature is enabled.

Instruction: [ChromeEarlGreyAppInterface
  isTestFeatureEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether kTestFeature is enabled.

Instruction: [ChromeEarlGreyAppInterface
  isDemographicMetricsReportingEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether DemographicMetricsReporting feature is enabled.

Instruction: [ChromeEarlGreyAppInterface
  appHasLaunchSwitch
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether the |launchSwitch| is found in host app launch switches.

Instruction: [ChromeEarlGreyAppInterface
  isCustomWebKitLoadedIfRequested
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether custom WebKit frameworks were properly loaded, rather than system frameworks
Extra: Always returns YES if the app was not requested to run with custom WebKit frameworks.

Instruction: [ChromeEarlGreyAppInterface
  isMobileModeByDefault
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: whether the mobile version of the websites are requested by default

Instruction: [ChromeEarlGreyAppInterface
  areMultipleWindowsSupported
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether the app is configured to, and running in an environment which can, open multiple windows.

Instruction: [ChromeEarlGreyAppInterface
  isContextMenuInWebViewEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether the new ContextMenu for web content feature is enabled.

Instruction: [ChromeEarlGreyAppInterface
  isNewOverflowMenuEnabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Whether the NewOverflowMenu feature is enabled

Instruction: [ChromeEarlGreyAppInterface
  popupPrefValue
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: Gets the current value of the popup content setting preference for the original browser state.

Instruction: [ChromeEarlGreyAppInterface
  setPopupPrefValue:value
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Sets the popup content setting preference to the given value for the original browser state.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  resetDesktopContentSetting
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Resets the desktop content setting to its default value.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  localStatePrefValue:prefName
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the value of a local state pref
Extra: Returns a base::Value encoded as a JSON string. If the pref was not registered, returns a Value of type NONE.

Instruction: [ChromeEarlGreyAppInterface
  setIntegerValue:value
  forLocalStatePref:prefName
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Sets the integer values for the local state pref with |prefName|
Context: chrome
Extra: |value| can be either a casted enum or any other numerical value. Local State contains the preferences that are shared between all browser states.

Instruction: [ChromeEarlGreyAppInterface
  userPrefValue:prefName
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: the value of a user pref in the original browser state
Extra: a base::Value encoded as a JSON string. If the pref was not registered, returns a Value of type NONE.

Instruction: [ChromeEarlGreyAppInterface
  setBoolValue:value
  forUserPref:prefName
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Sets the value of a boolean user pref in the original browser state.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  setIntegerValue:value
  forUserPref:prefName
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Sets the value of a integer user pref in the original browser state.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  resetBrowsingDataPrefs
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Resets the BrowsingDataPrefs, which defines if its selected or not when clearing Browsing data.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  setURLKeyedAnonymizedDataCollectionEnabled:enabled
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Enables or disables URL-keyed anonymized data collection.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  registeredKeyCommandCount
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The count of key commands registered with the currently active BVC.

Instruction: [ChromeEarlGreyAppInterface
  simulatePhysicalKeyboardEvent:input
  flags:flags
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Simulates a physical keyboard event.
The input is similar to UIKeyCommand parameters, and is designed for testing keyboard shortcuts.
Accepts any strings and also UIKeyInput{Up|Down|Left|Right}Arrow and UIKeyInputEscape constants as |input|.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  clearPasteboardURLs
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears the URLs stored in the pasteboard, from the tested app's perspective.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  pasteboardString
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The currently stored string on the pasteboard from the tested app's perspective.

Instruction: [ChromeEarlGreyAppInterface
  pasteboardURLSpec
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Context: chrome
Returns: The currently stored URL on the pasteboard from the tested app's perspective.

Instruction: [ChromeEarlGreyAppInterface
  watchForButtonsWithLabels:labels
  timeout:timeout
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Starts monitoring for buttons (based on traits) with the given (accessibility) |labels|. Monitoring will stop once all are found, or if timeout expires. If a previous set is currently being watched for it gets replaced with this set.
Context: chrome
Extra: Note that timeout is best effort and can be a bit longer than specified. This method returns immediately.

Instruction: [ChromeEarlGreyAppInterface
  watcherDetectedButtonWithLabel:label
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Whether the button with given (accessibility) |label| was observed at some point since |watchForButtonsWithLabels:timeout:| was called.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  stopWatcher
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clear the watcher list, stopping monitoring.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  clearDefaultBrowserPromoData
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Clears default browser promo data to restart capping for the promos.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  copyURLToPasteBoard
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Copies a chrome:// URL that doesn't require internet connection.
Context: chrome

Instruction: [ChromeEarlGreyAppInterface
  disableDefaultBrowserPromo
]
Page: https://source.chromium.org/chromium/chromium/src/+/main:ios/chrome/test/earl_grey/chrome_earl_grey_app_interface.h
Effect: Disables default browser promo. If a test needs to check a message drop down in a second window, this needs to be disabled or the popup will kill the message.
Context: chrome