File tree Expand file tree Collapse file tree
src/components/ContextOverlay/tests Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,11 +30,13 @@ describe("ContextMenu", () => {
3030 } ) ;
3131 it ( "if no placeholder is used the menu should be displayed on click" , async ( ) => {
3232 const { container } = render ( < ContextMenu { ...ContextMenuStory . args } preventPlaceholder = { true } /> ) ;
33+ checkForPlaceholderClass ( container , 0 ) ;
3334 fireEvent . click ( container . getElementsByClassName ( overlayWrapper ) [ 0 ] ) ;
3435 expect ( await screen . findByText ( "First option" ) ) . toBeVisible ( ) ;
3536 } ) ;
36- it ( "if placeholder is used the overlay should be displayed on click" , async ( ) => {
37- const { container } = render ( < ContextMenu { ...ContextMenuStory . args } usePlaceholder = { false } /> ) ;
37+ it ( "if placeholder is used the menu should be displayed on click" , async ( ) => {
38+ const { container } = render ( < ContextMenu { ...ContextMenuStory . args } preventPlaceholder = { false } /> ) ;
39+ checkForPlaceholderClass ( container , 1 ) ;
3840 fireEvent . click ( container . getElementsByClassName ( overlayWrapper ) [ 0 ] ) ;
3941 expect ( await screen . findByText ( "First option" ) ) . toBeVisible ( ) ;
4042 } ) ;
You can’t perform that action at this time.
0 commit comments