IKivan-kozenko -aqa
Try yourself as a QA tester
Back to topic

Quiz

Assertions

Check yourself

  1. 1.You click Submit and expect a success banner to appear. The banner is shown by an async API call. Which assertion should you use?
  2. 2.You want to check 5 fields on a confirmation page and see ALL failures at once, not stop at the first one. What do you use?
  3. 3.What is the difference between toHaveText() and toContainText()?
  4. 4.You want to assert that a table has exactly 10 data rows. Which assertion is correct?
  5. 5.A button should be disabled after a form is submitted. Which assertion correctly verifies this?
  6. 6.How do you assert that an element has a specific HTML attribute value, for example data-status='active'?
  7. 7.The default assertion timeout is 5 seconds. How do you change it to 10 seconds for all assertions in a project?
  8. 8.When should you use expect.poll() instead of a regular locator assertion?