@@ -551,3 +551,30 @@ def test_route_by_old_scid(node_factory, bitcoind):
551
551
wait_for (lambda : only_one (l1 .rpc .listpeers ()['peers' ])['connected' ] is True )
552
552
l1 .rpc .sendpay (route , inv2 ['payment_hash' ], payment_secret = inv2 ['payment_secret' ])
553
553
l1 .rpc .waitsendpay (inv2 ['payment_hash' ])
554
+
555
+
556
+ @pytest .mark .xfail (strict = True )
557
+ def test_splice_unannounced (node_factory , bitcoind ):
558
+ l1 , l2 = node_factory .line_graph (2 , fundamount = 1000000 , wait_for_announce = False , opts = {'experimental-splicing' : None })
559
+
560
+ chan_id = l1 .get_channel_id (l2 )
561
+
562
+ # add extra sats to pay fee
563
+ funds_result = l1 .rpc .fundpsbt ("109000sat" , "slow" , 166 , excess_as_change = True )
564
+ result = l1 .rpc .splice_init (chan_id , 100000 , funds_result ['psbt' ])
565
+ result = l1 .rpc .splice_update (chan_id , result ['psbt' ])
566
+ assert (result ['commitments_secured' ] is False )
567
+ result = l1 .rpc .splice_update (chan_id , result ['psbt' ])
568
+ assert (result ['commitments_secured' ] is True )
569
+ result = l1 .rpc .signpsbt (result ['psbt' ])
570
+ result = l1 .rpc .splice_signed (chan_id , result ['signed_psbt' ])
571
+
572
+ l2 .daemon .wait_for_log (r'CHANNELD_NORMAL to CHANNELD_AWAITING_SPLICE' )
573
+ l1 .daemon .wait_for_log (r'CHANNELD_NORMAL to CHANNELD_AWAITING_SPLICE' )
574
+
575
+ bitcoind .generate_block (1 , wait_for_mempool = 1 )
576
+
577
+ l2 .daemon .wait_for_log (r'CHANNELD_AWAITING_SPLICE to CHANNELD_NORMAL' )
578
+ l1 .daemon .wait_for_log (r'CHANNELD_AWAITING_SPLICE to CHANNELD_NORMAL' )
579
+ bitcoind .generate_block (1 )
580
+ sync_blockheight (bitcoind , [l1 , l2 ])
0 commit comments