diff --git a/packages/popup/test/lion-popup.test.js b/packages/popup/test/lion-popup.test.js index a8ead651d..9c6fd461a 100644 --- a/packages/popup/test/lion-popup.test.js +++ b/packages/popup/test/lion-popup.test.js @@ -22,12 +22,11 @@ describe('lion-popup', () => { `); const invoker = el.querySelector('[slot="invoker"]'); - const eventOnClick = new Event('click'); - invoker.dispatchEvent(eventOnClick); + invoker.click(); await el.updateComplete; expect(el.querySelector('[slot="content"]').style.display).to.be.equal('inline-block'); - invoker.dispatchEvent(eventOnClick); + invoker.click(); await el.updateComplete; expect(el.querySelector('[slot="content"]').style.display).to.be.equal('none'); });