Playwright · Senior · Question 34 of 77

How can a fixture fail tests that print console errors?

Show the answer

Correct answer: An auto fixture listens to console/pageerror and checks at the end

Explanation

Collecting errors and asserting after use() catches crashes that don't break the visible UI.

Further reading

Problem with a question

Playwright · Senior · question 34

Test yourself

Take the Playwright · Senior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz