What does it mean?
UI testing checks behavior through the user interface. A robust UI test verifies an outcome, not simply that a sequence of clicks was possible.
Model the user intent
Name scenarios by the behavior they validate, such as refusing an unauthorized change. Use actions and assertions that make that intent visible. A test named after a page tells reviewers little about its coverage.
Handle asynchronous states explicitly
Loading, error, empty, and completed states can all be important. Observe the relevant transition rather than assuming the interface settles after a fixed delay. Keep network and account fixtures controlled where possible.
Verify persistence and permissions
A confirmation banner can appear even when the underlying operation failed. Reload or inspect an appropriate state to validate persistence. Test role-denied paths separately from allowed paths so permission failures remain visible.
An unauthorized settings change
A viewer must not be able to modify billing settings.
- Use a viewer account with controlled permissions.
- Open the relevant settings state.
- Verify editing is denied according to the approved requirement.
- Use an authorized role in a separate isolated scenario to validate allowed behavior.
Illustrative scenario, not a customer result or a universal coverage promise.
Practical checklist
- Name scenarios by behavior.
- Cover important failure states.
- Assert persisted outcomes.
- Keep role tests isolated.
Sources and further reading
Use the linked technical documentation for current framework details. Adapt these practices to your product requirements and approved environment scope.