e2e: full coverage — 27 tests across all functionality #14
Loading…
Reference in a new issue
No description provided.
Delete branch "e2e/all-functionality"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Complete E2E test suite covering every functional area of the desktop app. Test file:
desktop/e2e/ui.spec.js(272 lines). All 27 tests pass against a real Spring Boot backend with H2 in-memory test database.Coverage
1. Login & Dashboard (2 tests)
Login flow: form renders with h1, username/password fields, submit navigates to app layoutDashboard shows stat cards: header confirms Dashboard, entity count cards for items/branches/bags/users are visible2. Entity pages — data table rendering (7 tests, one per entity)
Branches: table contains seed data row "Main Branch"Categories: table contains "E2E-Cat"Items: table contains "Test Item" (name + quantity visible)Bags: table contains barcode "TEST001"Roles: table contains rolename "admin"Users: table contains username "admin"Departments: table contains "Inbound"3. Permissions (1 test)
4. Locations (1 test)
5. Categories CRUD (3 tests, serial — share state)
Create: opens modal with "+ New", fills name field, clicks Save, verifies row appears in tbodyEdit: clicks row, changes name in modal, clicks Save, verifies updated name in tbodyDelete: clicks row, clicks Delete button, verifies name removed from tbody6. Filter/search (2 tests)
Filter works: types item name in .toolbar__search, matching row stays visibleFilter to empty: types nonsense string, empty-state "No data" appears7. Pagination (1 test)
8. Item inline form (1 test)
9. Scanner page (1 test)
10. Audit log (1 test)
11. Sidebar navigation (2 tests)
All 12 nav items present: each of 12 sidebar items resolves in DOMNavigate all pages: clicks each sidebar item, verifies header/h2 renders without error12. API CRUD verification (5 tests, raw fetch, no browser page)
Categories: POST creates with name, DELETE removes (verified by response ID)Departments: POST creates with name + branchId=1, DELETE removesItems: POST creates with name + quantity + unit + branchId + departmentId, DELETE removesBranches: POST creates with name + address + stateId + municipalityId + parishId, DELETE removesBags: POST creates with name + barcode + branchId + assignedDepartmentId, DELETE removesInfrastructure
SPRING_PROFILES_ACTIVE=test(H2 in-memory, Flyway disabled,create-dropschema)Results
27/27 passing, 45.5s total, all headed (visible browser session). TESTED ON:
devbranch commitdcba912.