Commit 5d7906d
committed
Resolves #6520
## Summary
Add 33 comprehensive E2E tests for the Admin Model Card Management page (`/admin-model-store`).
### Test Coverage (33 tests / 8 spec files)
| Spec File | Tests | Coverage |
|-----------|-------|----------|
| `page-load` | 4 | Page layout, pagination, column visibility |
| `filter` | 3 | Name filter, clear filter, empty state |
| `create` | 6 | Create modal, required/all fields, validation, cancel |
| `edit` | 4 | Edit modal, update fields, validation, cancel |
| `delete` | 6 | Single delete, cancel, bulk delete, bulk cancel, clear selection, select all |
| `access-control` | 2 | Non-admin URL access blocked, menu hidden |
| `sort-refresh` | 5 | Refresh, sort asc/desc, cross-column sort switch |
| `url-state` | 3 | Filter/sort/pagination URL state persistence |
## Test Recordings
### Access Control (2 tests)
| Test | Recording |
|------|-----------|
| Non-superadmin user cannot access the Admin Model Store page | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163245-access-control-non-superadmin-cannot-access.webm" controls width="960"></video> |
| Non-superadmin user does not see the Admin Model Store menu item in the sidebar | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163250-access-control-non-superadmin-no-sidebar-menu.webm" controls width="960"></video> |
### Create (6 tests)
| Test | Recording |
|------|-----------|
| Superadmin can open the Create Model Card modal | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163302-create-open-create-model-card-modal.webm" controls width="960"></video> |
| Superadmin can create a model card with only required fields | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163307-create-with-only-required-fields.webm" controls width="960"></video> |
| Superadmin can create a model card with all fields populated | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163313-create-with-all-fields-populated.webm" controls width="960"></video> |
| Superadmin cannot create a model card without a Name | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163319-create-cannot-create-without-name.webm" controls width="960"></video> |
| Superadmin cannot create a model card without a Model Storage Folder | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163324-create-cannot-create-without-storage-folder.webm" controls width="960"></video> |
| Superadmin can cancel the Create Model Card modal without creating anything | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163328-create-cancel-without-creating.webm" controls width="960"></video> |
### Delete (6 tests)
| Test | Recording |
|------|-----------|
| Superadmin can delete a model card via the trash icon with confirmation | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163345-delete-via-trash-icon-with-confirmation.webm" controls width="960"></video> |
| Superadmin can cancel a single-delete confirmation without deleting | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163353-delete-cancel-single-delete-confirmation.webm" controls width="960"></video> |
| Superadmin can select multiple model cards and delete them in bulk | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163357-delete-select-multiple-and-delete-in-bulk.webm" controls width="960"></video> |
| Superadmin can cancel bulk deletion | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163402-delete-cancel-bulk-deletion.webm" controls width="960"></video> |
| Superadmin can clear selection using the BAISelectionLabel clear button | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163406-delete-clear-selection-using-baiselectionlabel.webm" controls width="960"></video> |
| Superadmin can select all model cards on the current page using the header checkbox | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163410-delete-select-all-using-header-checkbox.webm" controls width="960"></video> |
### Edit (4 tests)
| Test | Recording |
|------|-----------|
| Superadmin can open the Edit Model Card modal from a table row | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163421-edit-open-edit-model-card-modal.webm" controls width="960"></video> |
| Superadmin can update a model card's metadata fields | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163426-edit-update-model-card-metadata-fields.webm" controls width="960"></video> |
| Superadmin cannot save an edit when the Name field is cleared | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163431-edit-cannot-save-when-name-field-cleared.webm" controls width="960"></video> |
| Superadmin can cancel the Edit modal without saving changes | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163435-edit-cancel-edit-modal-without-saving.webm" controls width="960"></video> |
### Filtering (3 tests)
| Test | Recording |
|------|-----------|
| Superadmin can filter model cards by name using BAIGraphQLPropertyFilter | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163445-filter-by-name-using-baigraphqlpropertyfilter.webm" controls width="960"></video> |
| Superadmin can clear a filter to restore the full list | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163450-filter-clear-filter-to-restore-full-list.webm" controls width="960"></video> |
| Superadmin sees empty table state when no model cards match the filter | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163454-filter-empty-state-when-no-cards-match.webm" controls width="960"></video> |
### Page Load and Table Display (4 tests)
| Test | Recording |
|------|-----------|
| Superadmin can view the Admin Model Card management page | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163505-page-load-view-admin-model-card-management-page.webm" controls width="960"></video> |
| Superadmin can see model card rows with correct data in the table | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163509-page-load-model-card-rows-with-correct-data.webm" controls width="960"></video> |
| Superadmin can see pagination controls and navigate between pages | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163515-page-load-pagination-controls-and-navigate.webm" controls width="960"></video> |
| Superadmin can change page size in the pagination | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163519-page-load-change-page-size-in-pagination.webm" controls width="960"></video> |
### Refresh and Sorting (5 tests)
| Test | Recording |
|------|-----------|
| Superadmin can refresh the table using the fetch key button | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163531-sort-refresh-refresh-using-fetch-key-button.webm" controls width="960"></video> |
| Superadmin can sort model cards by Name in ascending order | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163535-sort-refresh-sort-by-name-ascending.webm" controls width="960"></video> |
| Superadmin can sort model cards by Name in descending order | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163539-sort-refresh-sort-by-name-descending.webm" controls width="960"></video> |
| Superadmin can sort model cards by Created At | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163543-sort-refresh-sort-by-created-at.webm" controls width="960"></video> |
| Superadmin can switch sort from Name to Created At | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163547-sort-refresh-switch-sort-from-name-to-created-at.webm" controls width="960"></video> |
### URL State Persistence (3 tests)
| Test | Recording |
|------|-----------|
| Superadmin can persist filter state in the URL query parameters | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163556-url-state-persist-filter-state-in-url.webm" controls width="960"></video> |
| Superadmin can persist sort order in the URL query parameters | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163559-url-state-persist-sort-order-in-url.webm" controls width="960"></video> |
| Superadmin can persist pagination state in the URL query parameters | <video src="https://raw.githubusercontent.com/lablup/backend.ai-webui/assets/images/screenshots/pr-6521/20260409-163603-url-state-persist-pagination-state-in-url.webm" controls width="960"></video> |
1 parent 4e20153 commit 5d7906d
10 files changed
Lines changed: 1792 additions & 3 deletions
File tree
- e2e
- admin-model-card
- utils/classes
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
30 | 31 | | |
31 | 32 | | |
32 | 33 | | |
| |||
45 | 46 | | |
46 | 47 | | |
47 | 48 | | |
48 | | - | |
| 49 | + | |
49 | 50 | | |
50 | 51 | | |
51 | 52 | | |
| |||
377 | 378 | | |
378 | 379 | | |
379 | 380 | | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
380 | 419 | | |
381 | 420 | | |
382 | 421 | | |
| |||
Lines changed: 49 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
0 commit comments