@@ -3,7 +3,6 @@ import { mount } from "@vue/test-utils";
3
3
import { describe , expect , it } from "vitest" ;
4
4
import ChevronDownIcon from "./icons/ChevronDownIcon.vue" ;
5
5
import XMarkIcon from "./icons/XMarkIcon.vue" ;
6
- import Indicators from "./Indicators.vue" ;
7
6
import Select from "./Select.vue" ;
8
7
import Spinner from "./Spinner.vue" ;
9
8
@@ -65,7 +64,7 @@ describe("dropdown button rendering", () => {
65
64
66
65
it ( "should emit toggle event when dropdown button is clicked" , async ( ) => {
67
66
const wrapper = mount ( Select , { props : defaultProps } ) ;
68
- const indicators = wrapper . findComponent ( Indicators ) ;
67
+ const indicators = wrapper . getComponent ( { name : " Indicators" } ) ;
69
68
70
69
await wrapper . find ( ".dropdown-icon" ) . trigger ( "click" ) ;
71
70
expect ( indicators . emitted ( "toggle" ) ) . toStrictEqual ( [ [ ] ] ) ;
@@ -138,7 +137,7 @@ describe("clear button behavior", () => {
138
137
139
138
it ( "should emit clear event when clear button is clicked" , async ( ) => {
140
139
const wrapper = mount ( Select , { props : defaultProps } ) ;
141
- const indicators = wrapper . findComponent ( Indicators ) ;
140
+ const indicators = wrapper . getComponent ( { name : " Indicators" } ) ;
142
141
143
142
await wrapper . get ( "input" ) . trigger ( "mousedown" ) ;
144
143
await dispatchEvent ( wrapper , new KeyboardEvent ( "keydown" , { key : "Enter" } ) ) ;
0 commit comments