Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: some assertion methods #4144

Merged
merged 1 commit into from
Jan 23, 2024
Merged

fix: some assertion methods #4144

merged 1 commit into from
Jan 23, 2024

Conversation

kobenguyent
Copy link
Collaborator

Motivation/Description of the PR

  • Improve the error message for seeElement, dontSeeElement, seeElementInDOM, dontSeeElementInDOM

The current error message doesn't really help when debugging issue also causes some problem described in #4140

Actual

      expected visible elements '[ELEMENT]' to be empty
      + expected - actual

      -[
      -  "ELEMENT"
      -]
      +[]

Updated

     Error: Element "h1" is still visible
      at seeElementError (lib/helper/errors/ElementAssertion.js:9:9)
      at Playwright.dontSeeElement (lib/helper/Playwright.js:1472:7)

Applicable helpers:

  • Playwright
  • Puppeteer
  • WebDriver

Type of change

  • 馃悰 Bug fix

Checklist:

  • Tests have been added
  • Documentation has been added (Run npm run docs)
  • Lint checking (Run npm run lint)
  • Local tests are passed (Run npm test)

@kobenguyent
Copy link
Collaborator Author

Verified by #4140 (comment)

@kobenguyent kobenguyent merged commit 162b01b into 3.x Jan 23, 2024
14 checks passed
@kobenguyent kobenguyent deleted the fix-some-assertion-methods branch January 23, 2024 05:57
@kobenguyent kobenguyent mentioned this pull request Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Workers hang after a failed step with some assertions (webdriverio)
1 participant