File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ const MENU_PATHS = [
2525test . use ( { autoGoto : false } ) ;
2626
2727test . describe ( 'Notebook Menus' , ( ) => {
28- test . beforeEach ( async ( { page, tmpPath } ) => {
28+ test . beforeAll ( async ( { page, tmpPath } ) => {
2929 await page . contents . uploadFile (
3030 path . resolve ( __dirname , `./notebooks/${ NOTEBOOK } ` ) ,
3131 `${ tmpPath } /${ NOTEBOOK } `
@@ -40,7 +40,8 @@ test.describe('Notebook Menus', () => {
4040
4141 const imageName = `opened-menu-${ menuPath . replace ( / > / g, '-' ) } .png` ;
4242 const menu = await page . menu . getOpenMenu ( ) ;
43- expect ( await menu . screenshot ( ) ) . toMatchSnapshot ( imageName . toLowerCase ( ) ) ;
43+ expect ( menu ) . toBeDefined ( ) ;
44+ expect ( await menu ! . screenshot ( ) ) . toMatchSnapshot ( imageName . toLowerCase ( ) ) ;
4445 } ) ;
4546 } ) ;
4647} ) ;
You can’t perform that action at this time.
0 commit comments