Skip to content

Commit 1f20a38

Browse files
committed
refactor: initialize menu property in context menu controller tests
Signed-off-by: Wanjin Noh <[email protected]>
1 parent 1b04338 commit 1f20a38

File tree

1 file changed

+2
-2
lines changed
  • packages/mirinae/src/hooks/use-context-menu-controller/__tests__

1 file changed

+2
-2
lines changed

packages/mirinae/src/hooks/use-context-menu-controller/__tests__/index.test.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
import { createLocalVue, mount } from '@vue/test-utils';
22
import { defineComponent, ref } from 'vue';
33

4-
import { describe, expect } from 'vitest';
5-
64
import PContextMenu from '@/controls/context-menu/PContextMenu.vue';
75
import type { MenuItem } from '@/controls/context-menu/type';
86
import type { UseContextMenuControllerOptions } from '@/hooks/use-context-menu-controller/use-context-menu-controller';
@@ -105,6 +103,7 @@ describe('Context Menu Controller', () => {
105103
targetRef: ref<HTMLElement|null>(null),
106104
contextMenuRef: ref<any|null>(null),
107105
useReorderBySelection: true,
106+
menu: [],
108107
selected: [],
109108
}));
110109
expect(error).toBeFalsy();
@@ -146,6 +145,7 @@ describe('Context Menu Controller', () => {
146145
targetRef: ref<HTMLElement|null>(null),
147146
contextMenuRef: ref<any|null>(null),
148147
useMenuFiltering: true,
148+
menu: [],
149149
searchText: ref(''),
150150
}));
151151
expect(error).toBeFalsy();

0 commit comments

Comments
 (0)