DSingh0304 opened a new pull request, #3248:
URL: https://github.com/apache/apisix-dashboard/pull/3248

   **Why submit this pull request?**
   
   - [ ] Bugfix
   - [x] New feature provided
   - [ ] Improve performance
   - [ ] Backport patches
   
   **What changes will this PR take into?**
   
   This PR adds comprehensive E2E tests for the Global Rules resource, covering 
all CRUD operations and list page functionality.
   
   **Test Coverage (5 tests, all passing ✅):**
   
   - **List page tests (global_rules.list.spec.ts) - 3 tests**
     - Navigation to global rules page
     - Pagination using table controls
     - Pagination using URL search parameters
   
   - **CRUD with required fields (global_rules.crud-required-fields.spec.ts) - 
1 test**
     - Uses single plugin (response-rewrite)
     - Tests create and delete operations
   
   - **CRUD with all fields (global_rules.crud-all-fields.spec.ts) - 1 test**
     - Uses multiple plugins (response-rewrite + cors)
     - Tests create and delete operations with complex configurations
   
   **Files Added:**
   
   - `e2e/pom/global_rules.ts` - Page Object Model with navigation helpers and 
assertions
   - `e2e/tests/global_rules.list.spec.ts` - List page and pagination tests
   - `e2e/tests/global_rules.crud-required-fields.spec.ts` - Single plugin CRUD 
tests
   - `e2e/tests/global_rules.crud-all-fields.spec.ts` - Multiple plugins CRUD 
tests
   
   **Implementation Details:**
   
   - Uses Monaco editor for plugin JSON configuration (consistent with 
plugin_configs)
   - Proper handling of delete confirmation dialogs
   - Follows test patterns from routes, services, and plugin_metadata
   - Proper cleanup with deleteAllGlobalRules helper
   - Auto-generated ID capture and verification
   
   **Related issues**
   
   Closes #3088
   
   **Checklist:**
   
   - [x] Did you explain what problem does this PR solve? Or what new features 
have been added?
   - [x] Have you added corresponding test cases?
   - [ ] Have you modified the corresponding document? (N/A - E2E tests don't 
require documentation updates)
   - [x] Is this PR backward compatible? If it is not backward compatible, 
please discuss on the mailing list first (Yes, only adds tests, no breaking 
changes)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to