Skip to content

Commit

Permalink
tests: skip splicing / dual-funding tests when VLS_SKIP_SPLICE_TESTS
Browse files Browse the repository at this point in the history
  • Loading branch information
ksedgwic committed Nov 20, 2023
1 parent b1d16de commit 1d4e2e9
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/test_connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -584,6 +584,7 @@ def test_disconnect_fundee(node_factory):
assert len(l2.rpc.listpeers()) == 1


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_disconnect_fundee_v2(node_factory):
Expand Down Expand Up @@ -660,6 +661,7 @@ def test_disconnect_half_signed_v2(node_factory):
assert len(l1.rpc.listpeerchannels(l2.info['id'])['channels']) == 1


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
def test_reconnect_signed(node_factory):
Expand Down Expand Up @@ -1839,6 +1841,7 @@ def test_multifunding_v1_v2_mixed(node_factory, bitcoind):
l1.rpc.pay(inv)


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_multifunding_v2_exclusive(node_factory, bitcoind):
Expand Down
12 changes: 12 additions & 0 deletions tests/test_opening.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ def test_v2_open_sigs_reconnect_2(node_factory, bitcoind):
l2.daemon.wait_for_log(r'to CHANNELD_NORMAL')


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_v2_open_sigs_reconnect_1(node_factory, bitcoind):
Expand Down Expand Up @@ -337,6 +338,7 @@ def test_v2_open_sigs_restart_while_dead(node_factory, bitcoind):
l1.daemon.wait_for_log(r'to CHANNELD_NORMAL')


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_v2_rbf_single(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -519,6 +521,7 @@ def test_v2_rbf_abort_retry(node_factory, bitcoind, chainparams):
assert not l2.daemon.is_in_log('WIRE_CHANNEL_REESTABLISH')


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_v2_rbf_abort_channel_opens(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -675,6 +678,7 @@ def test_v2_rbf_liquidity_ad(node_factory, bitcoind, chainparams):
l1.daemon.wait_for_log('State changed from CLOSINGD_SIGEXCHANGE to CLOSINGD_COMPLETE')


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_v2_rbf_multi(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -865,6 +869,7 @@ def test_rbf_reconnect_ack(node_factory, bitcoind, chainparams):
l1.rpc.openchannel_bump(chan_id, chan_amount, initpsbt['psbt'])


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_rbf_reconnect_tx_construct(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -986,6 +991,7 @@ def test_rbf_reconnect_tx_construct(node_factory, bitcoind, chainparams):
l2.daemon.wait_for_log(r'to CHANNELD_NORMAL')


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_rbf_reconnect_tx_sigs(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -1067,6 +1073,7 @@ def test_rbf_reconnect_tx_sigs(node_factory, bitcoind, chainparams):
assert l1_funding_txid == l2_funding_txid


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_rbf_to_chain_before_commit(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -1168,6 +1175,7 @@ def test_rbf_no_overlap(node_factory, bitcoind, chainparams):
l1.rpc.openchannel_update(chan_id, bump['psbt'])


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_rbf_fails_to_broadcast(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -1249,6 +1257,7 @@ def run_retry():
assert last_txs['tx']


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_rbf_broadcast_close_inflights(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -1324,6 +1333,7 @@ def run_retry():
assert inflights[1]['scratch_txid'] not in bitcoind.rpc.getrawmempool()


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_rbf_non_last_mined(node_factory, bitcoind, chainparams):
Expand Down Expand Up @@ -1424,6 +1434,7 @@ def censoring_sendrawtx(r):
l1.daemon.wait_for_log(r'to ONCHAIN')


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
@pytest.mark.openchannel('v2')
def test_funder_options(node_factory, bitcoind):
Expand Down Expand Up @@ -2338,6 +2349,7 @@ def _no_utxo_response(r):
wait_for(lambda: l2.rpc.listpeerchannels()['channels'] == [])


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v2')
def test_openchannel_no_unconfirmed_inputs_accepter(node_factory, bitcoind):
""" If the accepter flags 'require-confirmed-inputs' for an open,
Expand Down
6 changes: 6 additions & 0 deletions tests/test_splicing.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
)


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down Expand Up @@ -48,6 +49,7 @@ def test_splice(node_factory, bitcoind):
assert l1.db_query("SELECT count(*) as c FROM channeltxs;")[0]['c'] == 0


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down Expand Up @@ -106,6 +108,7 @@ def test_splice_gossip(node_factory, bitcoind):
assert not l2.daemon.is_in_log("invalid local_channel_announcement")


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down Expand Up @@ -141,6 +144,7 @@ def test_splice_listnodes(node_factory, bitcoind):
assert len(l2.rpc.listnodes()['nodes']) == 2


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down Expand Up @@ -177,6 +181,7 @@ def test_splice_out(node_factory, bitcoind):
assert l1.db_query("SELECT count(*) as c FROM channeltxs;")[0]['c'] == 0


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down Expand Up @@ -288,6 +293,7 @@ def test_commit_crash_splice(node_factory, bitcoind):
assert l1.db_query("SELECT count(*) as c FROM channeltxs;")[0]['c'] == 0


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down
2 changes: 2 additions & 0 deletions tests/test_splicing_disconnect.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
)


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down Expand Up @@ -63,6 +64,7 @@ def test_splice_disconnect_sig(node_factory, bitcoind):
assert l1.db_query("SELECT count(*) as c FROM channeltxs;")[0]['c'] == 0


@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_SKIP_SPLICE_TESTS') == '1', "test expected to fail before VLS dual-funding / splicing support")
@pytest.mark.openchannel('v1')
@pytest.mark.openchannel('v2')
@unittest.skipIf(TEST_NETWORK != 'regtest', 'elementsd doesnt yet support PSBT features we need')
Expand Down

0 comments on commit 1d4e2e9

Please sign in to comment.