Testing CRUD Inertia từ backend
UI test có giá trị, nhưng phần lớn invariant của Inertia app nằm ở backend: route, auth, validation, query và response props. Feature test nên là lớp bảo vệ đầu tiên.Index response
Validation
Mutation + redirect
Authorization
Nên test gì ở frontend
Frontend test nên tập trung behavior riêng của UI:- nút submit disabled khi processing;
- error field hiển thị đúng;
- confirm delete chặn action khi cancel;
- filter giữ giá trị nhập;
- progress bar xuất hiện khi có upload progress.