Extract Work Item userPermissions to its own fragment for CE & EE
What does this MR do and why?
This merge request does a few things to handle different schema of WorkItem.userPermissions between EE & CE, and help with separating mock data for CE & EE tests.
- Creates a separate CE & EE fragments for
WorkItemPermissionsfield, where EE version containsblockedWorkItems, required to use for #505826 (closed). - Updates EE
ee/spec/frontend/work_items/mock_data.jssuch that;- It imports several mock objects/helpers from CE mock data
spec/frontend/work_items/mock_data.js. - Applies EE-specific fields on top of those.
- Exports those mock objects with same names.
- It imports several mock objects/helpers from CE mock data
- Updates specs within
spec/frontend/work_itemsto useee_else_ce_jestalias while importingmock_data.jswhere we're likely to run into different version of mock data between CE & EE contexts. - Updates specs within
ee/spec/frontend/work_itemsto use EE-specificmock_data.js.
Screenshots or screen recordings
NA
How to set up and validate locally
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.
Related to #505826 (closed)
Edited by Kushal Pandya