@@ -10,25 +10,25 @@ test.beforeEach(async ({ page }) => {
10
10
test . describe ( "Check basic text block appearance" , ( ) => {
11
11
test ( "Check basic text block appearance" , async ( { page } ) => {
12
12
focusOnEditor ( page ) ;
13
- await page . waitForTimeout ( 100 ) ;
13
+ await page . waitForTimeout ( 500 ) ;
14
+
15
+ await page . locator ( `[data-content-type="audio"] .bn-file-caption` ) . click ( ) ;
16
+ await page . keyboard . press ( "Backspace" ) ;
17
+ await page . waitForTimeout ( 500 ) ;
18
+
19
+ await page . locator ( `[data-content-type="video"] .bn-file-caption` ) . click ( ) ;
20
+ await page . keyboard . press ( "Backspace" ) ;
21
+ await page . waitForTimeout ( 500 ) ;
22
+
14
23
await page
15
24
. locator ( `${ PARAGRAPH_SELECTOR } > p` , {
16
25
hasText : "Welcome to this demo!" ,
17
26
} )
18
27
. click ( ) ;
19
28
20
- // Scroll to top of page.
21
- await page . mouse . wheel ( 0 , - 9999 ) ;
22
-
23
- await page . waitForTimeout ( 500 ) ;
24
- expect ( await page . screenshot ( ) ) . toMatchSnapshot ( "basic-blocks-top.png" ) ;
25
-
26
- // Scroll to bottom of page.
27
- await page . mouse . wheel ( 0 , 9999 ) ;
28
- // We have to scroll twice because Firefox gets stuck otherwise?
29
- await page . mouse . wheel ( 0 , 9999 ) ;
30
-
31
- await page . waitForTimeout ( 500 ) ;
32
- expect ( await page . screenshot ( ) ) . toMatchSnapshot ( "basic-blocks-bottom.png" ) ;
29
+ await page . waitForTimeout ( 100 ) ;
30
+ expect ( await page . screenshot ( { fullPage : true } ) ) . toMatchSnapshot (
31
+ "basicblocks.png" ,
32
+ ) ;
33
33
} ) ;
34
34
} ) ;
0 commit comments