🟡 MEDIUM - UI customization feature
Migrate Navigation Menu wdio tests to Cypress. These tests cover customizing and managing navigation menu items including drag-and-drop functionality.
-
navigation-menu.create-item.spec.ts- Creating menu items -
navigation-menu.delete-item.spec.ts- Deleting menu items -
navigation-menu.edit-item.spec.ts- Editing menu items -
navigation-menu.drag-item.spec.ts- Reordering via drag-and-drop
- wdio tests:
eform-client/e2e/Tests/navigation-menu/ - Target location:
eform-client/cypress/e2e/c/(subheader is already there)
✅ subheader.spec.ts - Already in cypress/e2e/c/
- Should create new navigation menu item
- Should set menu item name/label
- Should set menu item link/URL
- Should set menu item icon (if applicable)
- Should validate required fields
- Should verify item appears in menu
- Should edit existing menu item name
- Should edit menu item link
- Should edit menu item icon
- Should save changes successfully
- Should verify changes reflect in menu
- Should delete menu item with confirmation
- Should verify item removed from menu
- Should handle cancel deletion
- Should drag and drop menu item to reorder
- Should save new menu order
- Should verify order persists after page reload
- Should handle drag to different positions
- Action: Adapt/extend existing navigation page objects for Cypress
- Reference:
Navbar.page.tsexists in wdio
- Navigate to navigation menu settings/customization
- CRUD operations on menu items
- Drag-and-drop reordering
- Menu item properties (name, link, icon, order)
- Validation rules
- Menu rendering and display
- All 4 test files migrated to Cypress
- Tests follow existing Cypress patterns
- Page objects adapted for navigation menu management
- Drag-and-drop functionality working in Cypress
- All test scenarios covered
- Tests pass locally
- Tests pass in CI/CD pipeline
- Menu state properly reset between tests
- Drag-and-Drop: Cypress has specific commands/plugins for D&D
- Consider using
@4tw/cypress-drag-dropplugin if not already available - Or use native
.trigger()events
- Consider using
- Use
cy.intercept()for menu API calls - Ensure menu state is reset/cleaned up after tests
- Test both menu configuration and rendered menu display
// Option 1: Using plugin
cy.get('.menu-item').first().drag('.menu-item').last();
// Option 2: Using native events
cy.get('.menu-item').first()
.trigger('mousedown', { which: 1 })
.trigger('mousemove', { clientX: 100, clientY: 100 })
.trigger('mouseup');- Login functionality (already available in Cypress)
- Navigation to menu settings
- Subheader tests (already migrated)
Medium (3-4 hours) - Multiple tests with drag-and-drop complexity
Before closing this issue:
- All 4 test files passing
- Drag-and-drop working reliably
- Menu items created/edited/deleted correctly
- Menu order persists
- No leftover menu items after tests
- Tests are not flaky
- Cross-browser compatibility checked
- Code reviewed
- Update
WDIO_TO_CYPRESS_MIGRATION.mdprogress tracking