@@ -401,17 +401,6 @@ describe('Lightning wallets', function () {
401401 state : 'initialized' ,
402402 } ;
403403
404- const transferData = {
405- id : 'fake_id' ,
406- coin : 'tlnbtc' ,
407- state : 'confirmed' ,
408- txid : lndResponse . paymentHash ,
409- } ;
410-
411- const getTransferNock = nock ( bgUrl )
412- . get ( `/api/v2/${ coinName } /wallet/${ wallet . wallet . id ( ) } /transfer/fake_id` )
413- . reply ( 200 , transferData ) ;
414-
415404 const createTxRequestNock = nock ( bgUrl )
416405 . post ( `/api/v2/wallet/${ wallet . wallet . id ( ) } /txrequests` )
417406 . reply ( 200 , txRequestResponse ) ;
@@ -434,7 +423,6 @@ describe('Lightning wallets', function () {
434423 const response = await wallet . payInvoice ( params ) ;
435424 assert . strictEqual ( response . txRequestId , 'txReq123' ) ;
436425 assert . strictEqual ( response . txRequestState , 'delivered' ) ;
437- assert . strictEqual ( response . transfer . id , transferData . id ) ;
438426 assert . ok ( response . paymentStatus ) ;
439427 assert . strictEqual (
440428 response . paymentStatus . status ,
@@ -457,7 +445,6 @@ describe('Lightning wallets', function () {
457445 finalPaymentResponse . transactions [ 0 ] . unsignedTx . coinSpecific . paymentPreimage
458446 ) ;
459447
460- getTransferNock . done ( ) ;
461448 createTxRequestNock . done ( ) ;
462449 sendTxRequestNock . done ( ) ;
463450 createTransferNock . done ( ) ;
@@ -960,26 +947,6 @@ describe('Lightning wallets', function () {
960947 createdTime : '2025-06-09T07:47:16.102Z' ,
961948 } ;
962949
963- const updatedTransferResponse = {
964- ...transferResponse ,
965- txid : '211b8fb30990632751a83d1dc4f0323ff7d2fd3cad88084de13c9be2ae1c6426' ,
966- date : '2025-06-09T08:50:55.063Z' ,
967- state : 'signed' ,
968- history : [
969- {
970- date : '2025-06-09T07:50:55.063Z' ,
971- user : '6846918281f118cc42c33352779df88f' ,
972- action : 'signed' ,
973- } ,
974- {
975- date : '2025-06-09T07:47:16.102Z' ,
976- user : '6846918281f118cc42c33352779df88f' ,
977- action : 'created' ,
978- } ,
979- ] ,
980- signedTime : '2025-06-09T08:50:55.063Z' ,
981- } ;
982-
983950 const createTxRequestNock = nock ( bgUrl )
984951 . post ( `/api/v2/wallet/${ wallet . wallet . id ( ) } /txrequests` )
985952 . reply ( 200 , txRequestResponse ) ;
@@ -996,10 +963,6 @@ describe('Lightning wallets', function () {
996963 . post ( `/api/v2/wallet/${ wallet . wallet . id ( ) } /txrequests/${ txRequestResponse . txRequestId } /transactions/0/send` )
997964 . reply ( 200 , finalWithdrawResponse ) ;
998965
999- const getTransferNock = nock ( bgUrl )
1000- . get ( `/api/v2/${ coinName } /wallet/${ wallet . wallet . id ( ) } /transfer/${ transferResponse . id } ` )
1001- . reply ( 200 , updatedTransferResponse ) ;
1002-
1003966 const userAuthKeyNock = nock ( bgUrl )
1004967 . get ( '/api/v2/' + coinName + '/key/def' )
1005968 . reply ( 200 , userAuthKey ) ;
@@ -1013,15 +976,13 @@ describe('Lightning wallets', function () {
1013976 assert . strictEqual ( response . withdrawStatus ?. status , 'delivered' ) ;
1014977 assert . strictEqual ( response . withdrawStatus ?. txid , 'tx123' ) ;
1015978 assert . strictEqual ( ( response . withdrawStatus as any ) . signature , undefined ) ;
1016- assert . deepStrictEqual ( response . transfer , updatedTransferResponse ) ;
1017979
1018980 userAuthKeyNock . done ( ) ;
1019981 nodeAuthKeyNock . done ( ) ;
1020982 createTxRequestNock . done ( ) ;
1021983 storeSignatureNock . done ( ) ;
1022984 createTransferNock . done ( ) ;
1023985 sendTxRequestNock . done ( ) ;
1024- getTransferNock . done ( ) ;
1025986 } ) ;
1026987
1027988 it ( 'should handle pending approval when withdrawing onchain' , async function ( ) {
0 commit comments