Testing · Senior · Question 53 of 75
Why should E2E tests prefer seeding state via API instead of the UI?
- ✓Correct answer: UI setup is slow and fails for reasons unrelated to the feature under test; only the tested part should go through the UI
- 2APIs are always faster to write
- 3The UI can't create data
Explanation
Playwright's request fixture and Cypress's cy.request make API setup easy.