File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 11// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22// SPDX-License-Identifier: Apache-2.0
33
4+ import { waitFor } from '@testing-library/react' ;
5+
46import { BasePageObject } from '@cloudscape-design/browser-test-tools/page-objects' ;
57import useBrowser from '@cloudscape-design/browser-test-tools/use-browser' ;
68
@@ -345,8 +347,10 @@ test(
345347 await page . resizeColumn ( 2 , 100 ) ;
346348 const oldWidth = await page . getColumnWidth ( 2 ) ;
347349 await page . click ( '#reset-state' ) ;
348- const newWidth = await page . getColumnWidth ( 2 ) ;
349- expect ( oldWidth ) . toEqual ( newWidth ) ;
350+ await waitFor ( async ( ) => {
351+ const newWidth = await page . getColumnWidth ( 2 ) ;
352+ expect ( oldWidth ) . toEqual ( newWidth ) ;
353+ } ) ;
350354 } )
351355) ;
352356
You can’t perform that action at this time.
0 commit comments