Skip to content

use accessibility identifier for error modal #1162

Description

@tomholub
  checkError = async (errorText: string) => {
    const message = '-ios class chain:**/XCUIElementTypeAlert/XCUIElementTypeOther/XCUIElementTypeOther/' +
      'XCUIElementTypeOther[2]/XCUIElementTypeScrollView[1]/XCUIElementTypeOther[1]/XCUIElementTypeStaticText[2]';//it works only with this selector
    await expect(await this.errorHeader).toBeDisplayed();
    await expect(await $(message)).toHaveAttribute('value', `${errorText}`);
    await expect(await this.okButton).toBeDisplayed();
  }

I'd like this to be renamed to checkErrorModal and be moved to BaseScreen, so that it's reusable across the app.

We use the same code to render error modals everywhere, so we can use same code to check for it everywhere.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions