Skip to content

Commit 1019cc9

Browse files
committed
test: add test case
1 parent 3186b59 commit 1019cc9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/basic.test.jsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1220,11 +1220,13 @@ describe('Trigger.Basic', () => {
12201220
expect(isPopupHidden()).toBeFalsy();
12211221

12221222
// Click portal should not close
1223-
fireEvent.click(document.querySelector('.portal'));
1223+
fireEvent.pointerDown(document.querySelector('.portal'));
1224+
fireEvent.mouseDown(document.querySelector('.portal'));
12241225
await awaitFakeTimer();
12251226
expect(isPopupHidden()).toBeFalsy();
12261227

12271228
// Click outside to close
1229+
fireEvent.pointerDown(document.querySelector('.outer'));
12281230
fireEvent.mouseDown(container.querySelector('.outer'));
12291231
await awaitFakeTimer();
12301232
expect(isPopupHidden()).toBeTruthy();

0 commit comments

Comments
 (0)