@@ -356,9 +356,9 @@ describe('PaymentField', () => {
356356 // TODO - understand the difference between this test and the previous
357357 it ( 'should mark payment already captured' , async ( ) => {
358358 const mockRequest = { } as unknown as FormRequestPayload
359- // @ts -expect-error - partial mock
360359 jest
361360 . mocked ( get )
361+ // @ts -expect-error - partial mock
362362 . mockResolvedValueOnce ( { payload : { state : { status : 'success' } } } )
363363 await paymentField . onSubmit (
364364 mockRequest ,
@@ -381,9 +381,9 @@ describe('PaymentField', () => {
381381
382382 it ( 'should throw if bad status' , async ( ) => {
383383 const mockRequest = { } as unknown as FormRequestPayload
384- // @ts -expect-error - partial mock
385384 jest
386385 . mocked ( get )
386+ // @ts -expect-error - partial mock
387387 . mockResolvedValueOnce ( { payload : { state : { status : 'bad' } } } )
388388 await expect ( ( ) =>
389389 paymentField . onSubmit (
@@ -406,9 +406,9 @@ describe('PaymentField', () => {
406406
407407 it ( 'should throw if error during capture' , async ( ) => {
408408 const mockRequest = { } as unknown as FormRequestPayload
409- // @ts -expect-error - partial mock
410409 jest
411410 . mocked ( get )
411+ // @ts -expect-error - partial mock
412412 . mockResolvedValueOnce ( {
413413 payload : { state : { status : 'capturable' } }
414414 } )
@@ -435,9 +435,9 @@ describe('PaymentField', () => {
435435
436436 it ( 'should capture payment if no errors' , async ( ) => {
437437 const mockRequest = { } as unknown as FormRequestPayload
438- // @ts -expect-error - partial mock
439438 jest
440439 . mocked ( get )
440+ // @ts -expect-error - partial mock
441441 . mockResolvedValueOnce ( {
442442 payload : { state : { status : 'capturable' } }
443443 } )
0 commit comments