@@ -138,9 +138,9 @@ describe("Long Workflow instance creation unit tests", () => {
138138 id : INSTANCE_ID ,
139139 } ) ;
140140
141- expect (
142- instance . waitForStepResult ( { name : STEP_NAME } )
143- ) . resolves . toEqual ( mockResult ) ;
141+ expect ( await instance . waitForStepResult ( { name : STEP_NAME } ) ) . toEqual (
142+ mockResult
143+ ) ;
144144 await instance . waitForStatus ( "complete" ) ;
145145 return ( await createdInstance . status ( ) ) . status === "complete" ;
146146 } ,
@@ -194,9 +194,9 @@ describe("Long Workflow instance creation unit tests", () => {
194194 id : INSTANCE_ID ,
195195 } ) ;
196196
197- expect (
198- instance . waitForStepResult ( { name : STEP_NAME } )
199- ) . resolves . toEqual ( mockResult ) ;
197+ expect ( await instance . waitForStepResult ( { name : STEP_NAME } ) ) . toEqual (
198+ mockResult
199+ ) ;
200200 await instance . waitForStatus ( "complete" ) ;
201201 return ( await createdInstance . status ( ) ) . status === "complete" ;
202202 } ,
@@ -224,9 +224,9 @@ describe("Long Workflow instance creation unit tests", () => {
224224 id : INSTANCE_ID ,
225225 } ) ;
226226
227- expect (
228- instance . waitForStepResult ( { name : STEP_NAME } )
229- ) . resolves . toEqual ( mockResult ) ;
227+ expect ( await instance . waitForStepResult ( { name : STEP_NAME } ) ) . toEqual (
228+ mockResult
229+ ) ;
230230 await instance . waitForStatus ( "complete" ) ;
231231 return ( await createdInstance . status ( ) ) . status === "complete" ;
232232 } ,
@@ -341,7 +341,6 @@ describe("Long Workflow BATCH creation unit tests", () => {
341341 ] ) ;
342342
343343 instances = introspector . get ( ) ;
344- console . log ( "INSTANCES HELP AAAA" , instances ) ;
345344 assert ( instances . length === 3 ) ;
346345
347346 for ( const instance of instances ) {
@@ -493,9 +492,9 @@ describe("Long Workflow BATCH creation unit tests", () => {
493492 assert ( instances . length === 3 ) ;
494493
495494 for ( const instance of instances ) {
496- expect (
497- instance . waitForStepResult ( { name : STEP_NAME } )
498- ) . resolves . toEqual ( mockResult ) ;
495+ expect ( await instance . waitForStepResult ( { name : STEP_NAME } ) ) . toEqual (
496+ mockResult
497+ ) ;
499498 await instance . waitForStatus ( "complete" ) ;
500499 }
501500
@@ -579,9 +578,9 @@ describe("Long Workflow BATCH creation unit tests", () => {
579578 assert ( instances . length === 3 ) ;
580579
581580 for ( const instance of instances ) {
582- expect (
583- instance . waitForStepResult ( { name : STEP_NAME } )
584- ) . resolves . toEqual ( mockResult ) ;
581+ expect ( await instance . waitForStepResult ( { name : STEP_NAME } ) ) . toEqual (
582+ mockResult
583+ ) ;
585584 await instance . waitForStatus ( "complete" ) ;
586585 }
587586
@@ -624,9 +623,9 @@ describe("Long Workflow BATCH creation unit tests", () => {
624623 assert ( instances . length === 3 ) ;
625624
626625 for ( const instance of instances ) {
627- expect (
628- instance . waitForStepResult ( { name : STEP_NAME } )
629- ) . resolves . toEqual ( mockResult ) ;
626+ expect ( await instance . waitForStepResult ( { name : STEP_NAME } ) ) . toEqual (
627+ mockResult
628+ ) ;
630629 await instance . waitForStatus ( "complete" ) ;
631630 }
632631
0 commit comments