From f414529258c900541b36f15d2724b68a6b6fedca Mon Sep 17 00:00:00 2001 From: chad1008 <13856531+chad1008@users.noreply.github.com> Date: Wed, 3 Aug 2022 09:43:07 -0400 Subject: [PATCH] Update packages/components/src/combobox-control/test/index.js Co-authored-by: Marco Ciampini --- packages/components/src/combobox-control/test/index.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/components/src/combobox-control/test/index.js b/packages/components/src/combobox-control/test/index.js index 4999e355a36cef..2bcd980982eb4f 100644 --- a/packages/components/src/combobox-control/test/index.js +++ b/packages/components/src/combobox-control/test/index.js @@ -238,9 +238,11 @@ describe.each( [ // Pressing Enter/Return selects the currently focused option await user.keyboard( '{Enter}' ); - const itemSelectedAnnouncement = screen.getByText( 'Item selected.' ); - - expect( itemSelectedAnnouncement ).toBeInTheDocument(); + expect( + screen.getByText( 'Item selected.', { + selector: '[aria-live]', + } ) + ).toBeInTheDocument(); } ); it( 'should process multiple entries in a single session', async () => {