Migrate work items list label filtering to MSW

What does this MR do and why?

Migrates label filtering on the work items list from Capybara to an MSW integration test. All five operators (=, !=, None, Any, is one of) are covered, so the whole describe 'label' block is deleted from spec/features/work_items/list/user_applies_work_items_list_filters_spec.rb.

Notes for reviewers:

  • Labels only exist on getWorkItemsSlim, but rows are enriched from getWorkItemsFull. Both are filtered from fixtures generated with the same variables — filtering one alone lets the excluded rows back in.
  • Fixtures are generated per operator rather than filtering nodes in the handler, following the existing get_work_items_full_closed pattern. Reimplementing None/Any/negation/union semantics in JavaScript would mean asserting the test double instead of the app.
  • Each example asserts the requested variables as well as the rendered rows. With the current fixture seed, != To Do and None return the same work items, so the variables are what keep the two cases distinguishable.
  • assignRouter is called inside the mount helper rather than at describe level (the pattern in the other list specs) because each example boots the app on a different URL.

The remaining filter dimensions need a richer fixture seed — every seeded work item shares one author, and only one carries a label — so they stay in Capybara for now.

Runtime saved

Value
Capybara file on master (averaged) 150.1s
The two label examples removed 42.5s (13.3% of the file)
MSW replacement 6s
Net saving per CI run ~20s

References

Screenshots or screen recordings

Not applicable — test-only change, no UI changes.

How to set up and validate locally

  1. Generate the fixtures:

    bundle exec rspec ee/spec/frontend/fixtures/work_items_integration.rb
  2. Run the new spec:

    yarn jest:msw-integration ee/spec/frontend/msw_integration/work_items/list/label_filter_spec.js
  3. Run the whole MSW suite to confirm no regressions:

    yarn jest:msw-integration

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Vedant Jain

Merge request reports

Loading
Loading