Fix FOSS specs running under EE
There were a few problems here: 1. The implementation imports some components from `ee_else_ce`, while the FOSS spec was importing all from FOSS. This meant that the spec was asserting against the wrong component. 2. The EE components have injections without default values. Under Vue 3, this results in a warning being logged, which fails the test. The tests now provide sensible values for those injections. 3. It seems that calling `wrapper.props()` on a Vue wrapper wrapping a component that extends another component doesn't work as expected under Vue 3. The props object is empty, as if the component doesn't define any props. This is either a bug in `@vue/test-utils@2`, or a bug in our compat layer `vue-test-utils-compat`. The workaround for now is to explicitly redeclare the props on the component that extends the other.
显示
- app/assets/javascripts/vue_shared/components/filtered_search_bar/filtered_search_bar_root.vue 2 个添加, 4 个删除...mponents/filtered_search_bar/filtered_search_bar_root.vue
- ee/app/assets/javascripts/boards/components/boards_selector.vue 4 个添加, 0 个删除.../assets/javascripts/boards/components/boards_selector.vue
- scripts/frontend/quarantined_vue3_specs.txt 0 个添加, 1 个删除scripts/frontend/quarantined_vue3_specs.txt
- spec/frontend/boards/components/board_top_bar_spec.js 5 个添加, 2 个删除spec/frontend/boards/components/board_top_bar_spec.js
加载中
想要评论请 注册 或 登录