@@ -11,7 +11,7 @@ import { html } from "./plugin-html";
11
11
setEnv ( "*" ) ;
12
12
registerContainers ( ) ;
13
13
14
- test ( "paste html fragment" , ( ) => {
14
+ test ( "paste html fragment" , async ( ) => {
15
15
const data = renderData (
16
16
< ws . element ws :tag = "body" ws :id = "bodyId" >
17
17
< ws . element ws :tag = "div" ws :id = "divId" > </ ws . element >
@@ -24,7 +24,7 @@ test("paste html fragment", () => {
24
24
) ;
25
25
$awareness . set ( { pageId : "pageId" , instanceSelector : [ "divId" , "bodyId" ] } ) ;
26
26
expect (
27
- html . onPaste ?.( `
27
+ await html . onPaste ?.( `
28
28
<section>
29
29
<h1>It works</h1>
30
30
</section>
@@ -48,7 +48,7 @@ test("paste html fragment", () => {
48
48
) ;
49
49
} ) ;
50
50
51
- test ( "ignore html without any tags" , ( ) => {
51
+ test ( "ignore html without any tags" , async ( ) => {
52
52
const data = renderData (
53
53
< ws . element ws :tag = "body" ws :id = "bodyId" >
54
54
< ws . element ws :tag = "div" ws :id = "divId" > </ ws . element >
@@ -60,6 +60,6 @@ test("ignore html without any tags", () => {
60
60
createDefaultPages ( { rootInstanceId : "bodyId" , homePageId : "pageId" } )
61
61
) ;
62
62
$awareness . set ( { pageId : "pageId" , instanceSelector : [ "divId" , "bodyId" ] } ) ;
63
- expect ( html . onPaste ?.( `It works` ) ) . toEqual ( false ) ;
63
+ expect ( await html . onPaste ?.( `It works` ) ) . toEqual ( false ) ;
64
64
expect ( $instances . get ( ) ) . toEqual ( data . instances ) ;
65
65
} ) ;
0 commit comments