Playwright · Senior · Question 15 of 77
Mocking all APIs makes E2E tests fast. What is the main risk?
- 1Playwright can mock only GET requests reliably
- 2Mocks make tests slower than the real backend
- 3Tests pass while the frontend and real backend disagree
Show the answer
Correct answer: Tests pass while the frontend and real backend disagree
Explanation
Mocked tests check the UI against your assumptions. Keep some tests against a real backend, or add contract tests to catch drift.