From a0473442d1c22043f5a288bd9255c006fd85d947 Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Tue, 16 Jul 2024 22:05:14 +0100 Subject: [PATCH 1/3] scripted-diff: Add `__file__` argument to `BitcoinTestFramework.init()` -BEGIN VERIFY SCRIPT- sed -i -e 's/\s*().main\s*()/(__file__).main()/' $(git ls-files test/functional/*.py) sed -i -e 's/def __init__(self)/def __init__(self, test_file)/' test/functional/test_framework/test_framework.py -END VERIFY SCRIPT- --- test/functional/create_cache.py | 2 +- test/functional/example_test.py | 2 +- test/functional/feature_abortnode.py | 2 +- test/functional/feature_addrman.py | 2 +- test/functional/feature_anchors.py | 2 +- test/functional/feature_asmap.py | 2 +- test/functional/feature_assumeutxo.py | 2 +- test/functional/feature_assumevalid.py | 2 +- test/functional/feature_bind_extra.py | 2 +- test/functional/feature_bind_port_discover.py | 2 +- test/functional/feature_bind_port_externalip.py | 2 +- test/functional/feature_bip68_sequence.py | 2 +- test/functional/feature_block.py | 2 +- test/functional/feature_blocksdir.py | 2 +- test/functional/feature_cltv.py | 2 +- test/functional/feature_coinstatsindex.py | 2 +- test/functional/feature_config_args.py | 2 +- test/functional/feature_csv_activation.py | 2 +- test/functional/feature_dbcrash.py | 2 +- test/functional/feature_dersig.py | 2 +- test/functional/feature_dirsymlinks.py | 2 +- test/functional/feature_discover.py | 2 +- test/functional/feature_fastprune.py | 2 +- test/functional/feature_fee_estimation.py | 2 +- test/functional/feature_filelock.py | 2 +- test/functional/feature_framework_miniwallet.py | 2 +- test/functional/feature_help.py | 2 +- test/functional/feature_includeconf.py | 2 +- test/functional/feature_index_prune.py | 2 +- test/functional/feature_init.py | 2 +- test/functional/feature_loadblock.py | 2 +- test/functional/feature_logging.py | 2 +- test/functional/feature_maxtipage.py | 2 +- test/functional/feature_maxuploadtarget.py | 2 +- test/functional/feature_minchainwork.py | 2 +- test/functional/feature_notifications.py | 2 +- test/functional/feature_nulldummy.py | 2 +- test/functional/feature_posix_fs_permissions.py | 2 +- test/functional/feature_presegwit_node_upgrade.py | 2 +- test/functional/feature_proxy.py | 2 +- test/functional/feature_pruning.py | 2 +- test/functional/feature_rbf.py | 2 +- test/functional/feature_reindex.py | 2 +- test/functional/feature_reindex_readonly.py | 2 +- test/functional/feature_remove_pruned_files_on_startup.py | 2 +- test/functional/feature_segwit.py | 2 +- test/functional/feature_settings.py | 2 +- test/functional/feature_shutdown.py | 2 +- test/functional/feature_signet.py | 2 +- test/functional/feature_startupnotify.py | 2 +- test/functional/feature_taproot.py | 2 +- test/functional/feature_uacomment.py | 2 +- test/functional/feature_unsupported_utxo_db.py | 2 +- test/functional/feature_utxo_set_hash.py | 2 +- test/functional/feature_versionbits_warning.py | 2 +- test/functional/interface_bitcoin_cli.py | 2 +- test/functional/interface_http.py | 2 +- test/functional/interface_rest.py | 2 +- test/functional/interface_rpc.py | 2 +- test/functional/interface_usdt_coinselection.py | 2 +- test/functional/interface_usdt_mempool.py | 2 +- test/functional/interface_usdt_net.py | 2 +- test/functional/interface_usdt_utxocache.py | 2 +- test/functional/interface_usdt_validation.py | 2 +- test/functional/interface_zmq.py | 2 +- test/functional/mempool_accept.py | 2 +- test/functional/mempool_accept_wtxid.py | 2 +- test/functional/mempool_compatibility.py | 2 +- test/functional/mempool_datacarrier.py | 2 +- test/functional/mempool_dust.py | 2 +- test/functional/mempool_expiry.py | 2 +- test/functional/mempool_limit.py | 2 +- test/functional/mempool_package_limits.py | 2 +- test/functional/mempool_package_onemore.py | 2 +- test/functional/mempool_package_rbf.py | 2 +- test/functional/mempool_packages.py | 2 +- test/functional/mempool_persist.py | 2 +- test/functional/mempool_reorg.py | 2 +- test/functional/mempool_resurrect.py | 2 +- test/functional/mempool_sigoplimit.py | 2 +- test/functional/mempool_spend_coinbase.py | 2 +- test/functional/mempool_truc.py | 2 +- test/functional/mempool_unbroadcast.py | 2 +- test/functional/mempool_updatefromblock.py | 2 +- test/functional/mining_basic.py | 2 +- test/functional/mining_getblocktemplate_longpoll.py | 2 +- test/functional/mining_prioritisetransaction.py | 2 +- test/functional/p2p_1p1c_network.py | 2 +- test/functional/p2p_add_connections.py | 2 +- test/functional/p2p_addr_relay.py | 2 +- test/functional/p2p_addrfetch.py | 2 +- test/functional/p2p_addrv2_relay.py | 2 +- test/functional/p2p_block_sync.py | 2 +- test/functional/p2p_blockfilters.py | 2 +- test/functional/p2p_blocksonly.py | 2 +- test/functional/p2p_compactblocks.py | 2 +- test/functional/p2p_compactblocks_blocksonly.py | 2 +- test/functional/p2p_compactblocks_hb.py | 2 +- test/functional/p2p_disconnect_ban.py | 2 +- test/functional/p2p_dns_seeds.py | 2 +- test/functional/p2p_dos_header_tree.py | 2 +- test/functional/p2p_eviction.py | 2 +- test/functional/p2p_feefilter.py | 2 +- test/functional/p2p_filter.py | 2 +- test/functional/p2p_fingerprint.py | 2 +- test/functional/p2p_getaddr_caching.py | 2 +- test/functional/p2p_getdata.py | 2 +- test/functional/p2p_handshake.py | 2 +- test/functional/p2p_headers_sync_with_minchainwork.py | 2 +- test/functional/p2p_i2p_ports.py | 2 +- test/functional/p2p_i2p_sessions.py | 2 +- test/functional/p2p_ibd_stalling.py | 2 +- test/functional/p2p_ibd_txrelay.py | 2 +- test/functional/p2p_initial_headers_sync.py | 2 +- test/functional/p2p_invalid_block.py | 2 +- test/functional/p2p_invalid_locator.py | 2 +- test/functional/p2p_invalid_messages.py | 2 +- test/functional/p2p_invalid_tx.py | 2 +- test/functional/p2p_leak.py | 2 +- test/functional/p2p_leak_tx.py | 2 +- test/functional/p2p_message_capture.py | 2 +- test/functional/p2p_mutated_blocks.py | 2 +- test/functional/p2p_net_deadlock.py | 2 +- test/functional/p2p_nobloomfilter_messages.py | 2 +- test/functional/p2p_node_network_limited.py | 2 +- test/functional/p2p_opportunistic_1p1c.py | 2 +- test/functional/p2p_orphan_handling.py | 2 +- test/functional/p2p_outbound_eviction.py | 2 +- test/functional/p2p_permissions.py | 2 +- test/functional/p2p_ping.py | 2 +- test/functional/p2p_segwit.py | 2 +- test/functional/p2p_sendheaders.py | 2 +- test/functional/p2p_sendtxrcncl.py | 2 +- test/functional/p2p_timeouts.py | 2 +- test/functional/p2p_tx_download.py | 2 +- test/functional/p2p_tx_privacy.py | 2 +- test/functional/p2p_unrequested_blocks.py | 2 +- test/functional/p2p_v2_encrypted.py | 2 +- test/functional/p2p_v2_misbehaving.py | 2 +- test/functional/p2p_v2_transport.py | 2 +- test/functional/rpc_bind.py | 2 +- test/functional/rpc_blockchain.py | 2 +- test/functional/rpc_createmultisig.py | 2 +- test/functional/rpc_decodescript.py | 2 +- test/functional/rpc_deprecated.py | 2 +- test/functional/rpc_deriveaddresses.py | 2 +- test/functional/rpc_dumptxoutset.py | 2 +- test/functional/rpc_estimatefee.py | 2 +- test/functional/rpc_generate.py | 2 +- test/functional/rpc_getblockfilter.py | 2 +- test/functional/rpc_getblockfrompeer.py | 2 +- test/functional/rpc_getblockstats.py | 2 +- test/functional/rpc_getchaintips.py | 2 +- test/functional/rpc_getdescriptorinfo.py | 2 +- test/functional/rpc_help.py | 2 +- test/functional/rpc_invalid_address_message.py | 2 +- test/functional/rpc_invalidateblock.py | 2 +- test/functional/rpc_mempool_info.py | 2 +- test/functional/rpc_misc.py | 2 +- test/functional/rpc_named_arguments.py | 2 +- test/functional/rpc_net.py | 2 +- test/functional/rpc_packages.py | 2 +- test/functional/rpc_preciousblock.py | 2 +- test/functional/rpc_psbt.py | 2 +- test/functional/rpc_rawtransaction.py | 2 +- test/functional/rpc_scanblocks.py | 2 +- test/functional/rpc_scantxoutset.py | 2 +- test/functional/rpc_setban.py | 2 +- test/functional/rpc_signer.py | 2 +- test/functional/rpc_signmessagewithprivkey.py | 2 +- test/functional/rpc_signrawtransactionwithkey.py | 2 +- test/functional/rpc_txoutproof.py | 2 +- test/functional/rpc_uptime.py | 2 +- test/functional/rpc_users.py | 2 +- test/functional/rpc_validateaddress.py | 2 +- test/functional/rpc_whitelist.py | 2 +- test/functional/test_framework/test_framework.py | 2 +- test/functional/tool_signet_miner.py | 2 +- test/functional/tool_wallet.py | 2 +- test/functional/wallet_abandonconflict.py | 2 +- test/functional/wallet_address_types.py | 2 +- test/functional/wallet_assumeutxo.py | 2 +- test/functional/wallet_avoid_mixing_output_types.py | 2 +- test/functional/wallet_avoidreuse.py | 2 +- test/functional/wallet_backup.py | 2 +- test/functional/wallet_backwards_compatibility.py | 2 +- test/functional/wallet_balance.py | 2 +- test/functional/wallet_basic.py | 2 +- test/functional/wallet_blank.py | 2 +- test/functional/wallet_bumpfee.py | 2 +- test/functional/wallet_change_address.py | 2 +- test/functional/wallet_coinbase_category.py | 2 +- test/functional/wallet_conflicts.py | 2 +- test/functional/wallet_create_tx.py | 2 +- test/functional/wallet_createwallet.py | 2 +- test/functional/wallet_createwalletdescriptor.py | 2 +- test/functional/wallet_crosschain.py | 2 +- test/functional/wallet_descriptor.py | 2 +- test/functional/wallet_disable.py | 2 +- test/functional/wallet_dump.py | 2 +- test/functional/wallet_encryption.py | 2 +- test/functional/wallet_fallbackfee.py | 2 +- test/functional/wallet_fast_rescan.py | 2 +- test/functional/wallet_fundrawtransaction.py | 2 +- test/functional/wallet_gethdkeys.py | 2 +- test/functional/wallet_groups.py | 2 +- test/functional/wallet_hd.py | 2 +- test/functional/wallet_implicitsegwit.py | 2 +- test/functional/wallet_import_rescan.py | 2 +- test/functional/wallet_import_with_label.py | 2 +- test/functional/wallet_importdescriptors.py | 2 +- test/functional/wallet_importmulti.py | 2 +- test/functional/wallet_importprunedfunds.py | 2 +- test/functional/wallet_inactive_hdchains.py | 2 +- test/functional/wallet_keypool.py | 2 +- test/functional/wallet_keypool_topup.py | 2 +- test/functional/wallet_labels.py | 2 +- test/functional/wallet_listdescriptors.py | 2 +- test/functional/wallet_listreceivedby.py | 2 +- test/functional/wallet_listsinceblock.py | 2 +- test/functional/wallet_listtransactions.py | 2 +- test/functional/wallet_migration.py | 2 +- test/functional/wallet_miniscript.py | 2 +- test/functional/wallet_multisig_descriptor_psbt.py | 2 +- test/functional/wallet_multiwallet.py | 2 +- test/functional/wallet_orphanedreward.py | 2 +- test/functional/wallet_pruning.py | 2 +- test/functional/wallet_reindex.py | 2 +- test/functional/wallet_reorgsrestore.py | 2 +- test/functional/wallet_rescan_unconfirmed.py | 2 +- test/functional/wallet_resendwallettransactions.py | 2 +- test/functional/wallet_send.py | 2 +- test/functional/wallet_sendall.py | 2 +- test/functional/wallet_sendmany.py | 2 +- test/functional/wallet_signer.py | 2 +- test/functional/wallet_signmessagewithaddress.py | 2 +- test/functional/wallet_signrawtransactionwithwallet.py | 2 +- test/functional/wallet_simulaterawtx.py | 2 +- test/functional/wallet_spend_unconfirmed.py | 2 +- test/functional/wallet_startup.py | 2 +- test/functional/wallet_taproot.py | 2 +- test/functional/wallet_timelock.py | 2 +- test/functional/wallet_transactiontime_rescan.py | 2 +- test/functional/wallet_txn_clone.py | 2 +- test/functional/wallet_txn_doublespend.py | 2 +- test/functional/wallet_upgradewallet.py | 2 +- test/functional/wallet_watchonly.py | 2 +- 247 files changed, 247 insertions(+), 247 deletions(-) diff --git a/test/functional/create_cache.py b/test/functional/create_cache.py index 1108a8e3544be..0702ea76665fa 100755 --- a/test/functional/create_cache.py +++ b/test/functional/create_cache.py @@ -24,4 +24,4 @@ def run_test(self): pass if __name__ == '__main__': - CreateCache().main() + CreateCache(__file__).main() diff --git a/test/functional/example_test.py b/test/functional/example_test.py index 7f7aa065adcfe..39cea2962ff23 100755 --- a/test/functional/example_test.py +++ b/test/functional/example_test.py @@ -225,4 +225,4 @@ def run_test(self): if __name__ == '__main__': - ExampleTest().main() + ExampleTest(__file__).main() diff --git a/test/functional/feature_abortnode.py b/test/functional/feature_abortnode.py index 01ba2834c4221..a5c8aa163aae4 100755 --- a/test/functional/feature_abortnode.py +++ b/test/functional/feature_abortnode.py @@ -42,4 +42,4 @@ def run_test(self): if __name__ == '__main__': - AbortNodeTest().main() + AbortNodeTest(__file__).main() diff --git a/test/functional/feature_addrman.py b/test/functional/feature_addrman.py index 2efad709008f7..c4e60fba1236f 100755 --- a/test/functional/feature_addrman.py +++ b/test/functional/feature_addrman.py @@ -160,4 +160,4 @@ def run_test(self): if __name__ == "__main__": - AddrmanTest().main() + AddrmanTest(__file__).main() diff --git a/test/functional/feature_anchors.py b/test/functional/feature_anchors.py index 5d68f50f582be..5ca46c1366440 100755 --- a/test/functional/feature_anchors.py +++ b/test/functional/feature_anchors.py @@ -141,4 +141,4 @@ def run_test(self): if __name__ == "__main__": - AnchorsTest().main() + AnchorsTest(__file__).main() diff --git a/test/functional/feature_asmap.py b/test/functional/feature_asmap.py index e469deef49d35..cbff028bcc358 100755 --- a/test/functional/feature_asmap.py +++ b/test/functional/feature_asmap.py @@ -146,4 +146,4 @@ def run_test(self): if __name__ == '__main__': - AsmapTest().main() + AsmapTest(__file__).main() diff --git a/test/functional/feature_assumeutxo.py b/test/functional/feature_assumeutxo.py index 688e2866b2704..f4d7c47d1389a 100755 --- a/test/functional/feature_assumeutxo.py +++ b/test/functional/feature_assumeutxo.py @@ -555,4 +555,4 @@ class Block: chain_tx: int if __name__ == '__main__': - AssumeutxoTest().main() + AssumeutxoTest(__file__).main() diff --git a/test/functional/feature_assumevalid.py b/test/functional/feature_assumevalid.py index 982fa799151ab..03a9f666b2a71 100755 --- a/test/functional/feature_assumevalid.py +++ b/test/functional/feature_assumevalid.py @@ -172,4 +172,4 @@ def run_test(self): if __name__ == '__main__': - AssumeValidTest().main() + AssumeValidTest(__file__).main() diff --git a/test/functional/feature_bind_extra.py b/test/functional/feature_bind_extra.py index ed2328b76f7f5..6b53de188f43b 100755 --- a/test/functional/feature_bind_extra.py +++ b/test/functional/feature_bind_extra.py @@ -88,4 +88,4 @@ def run_test(self): assert_equal(binds, set(expected_services)) if __name__ == '__main__': - BindExtraTest().main() + BindExtraTest(__file__).main() diff --git a/test/functional/feature_bind_port_discover.py b/test/functional/feature_bind_port_discover.py index 6e07f2f16c836..568c88bcbea7e 100755 --- a/test/functional/feature_bind_port_discover.py +++ b/test/functional/feature_bind_port_discover.py @@ -75,4 +75,4 @@ def run_test(self): assert found_addr1 if __name__ == '__main__': - BindPortDiscoverTest().main() + BindPortDiscoverTest(__file__).main() diff --git a/test/functional/feature_bind_port_externalip.py b/test/functional/feature_bind_port_externalip.py index 6a74ce5738a25..8e2ac02470a51 100755 --- a/test/functional/feature_bind_port_externalip.py +++ b/test/functional/feature_bind_port_externalip.py @@ -72,4 +72,4 @@ def run_test(self): assert found if __name__ == '__main__': - BindPortExternalIPTest().main() + BindPortExternalIPTest(__file__).main() diff --git a/test/functional/feature_bip68_sequence.py b/test/functional/feature_bip68_sequence.py index 14b92d6733a88..2d61987e944db 100755 --- a/test/functional/feature_bip68_sequence.py +++ b/test/functional/feature_bip68_sequence.py @@ -412,4 +412,4 @@ def test_version2_relay(self): if __name__ == '__main__': - BIP68Test().main() + BIP68Test(__file__).main() diff --git a/test/functional/feature_block.py b/test/functional/feature_block.py index 932f37a083815..172af278482f5 100755 --- a/test/functional/feature_block.py +++ b/test/functional/feature_block.py @@ -1434,4 +1434,4 @@ def send_blocks(self, blocks, success=True, reject_reason=None, force_send=False if __name__ == '__main__': - FullBlockTest().main() + FullBlockTest(__file__).main() diff --git a/test/functional/feature_blocksdir.py b/test/functional/feature_blocksdir.py index 1a60c13c2c8f9..4a43632855722 100755 --- a/test/functional/feature_blocksdir.py +++ b/test/functional/feature_blocksdir.py @@ -35,4 +35,4 @@ def run_test(self): if __name__ == '__main__': - BlocksdirTest().main() + BlocksdirTest(__file__).main() diff --git a/test/functional/feature_cltv.py b/test/functional/feature_cltv.py index fb3f6622719e1..dc01f8fa8f068 100755 --- a/test/functional/feature_cltv.py +++ b/test/functional/feature_cltv.py @@ -195,4 +195,4 @@ def run_test(self): if __name__ == '__main__': - BIP65Test().main() + BIP65Test(__file__).main() diff --git a/test/functional/feature_coinstatsindex.py b/test/functional/feature_coinstatsindex.py index 691163d0532ac..b4392e6002e82 100755 --- a/test/functional/feature_coinstatsindex.py +++ b/test/functional/feature_coinstatsindex.py @@ -324,4 +324,4 @@ def _test_init_index_after_reorg(self): if __name__ == '__main__': - CoinStatsIndexTest().main() + CoinStatsIndexTest(__file__).main() diff --git a/test/functional/feature_config_args.py b/test/functional/feature_config_args.py index 9e13a3deefa19..dc812d224fc80 100755 --- a/test/functional/feature_config_args.py +++ b/test/functional/feature_config_args.py @@ -431,4 +431,4 @@ def run_test(self): if __name__ == '__main__': - ConfArgsTest().main() + ConfArgsTest(__file__).main() diff --git a/test/functional/feature_csv_activation.py b/test/functional/feature_csv_activation.py index 2db9682931540..df02bcc6ad8d8 100755 --- a/test/functional/feature_csv_activation.py +++ b/test/functional/feature_csv_activation.py @@ -482,4 +482,4 @@ def run_test(self): if __name__ == '__main__': - BIP68_112_113Test().main() + BIP68_112_113Test(__file__).main() diff --git a/test/functional/feature_dbcrash.py b/test/functional/feature_dbcrash.py index afd0246209f5e..f1aa3961e33ad 100755 --- a/test/functional/feature_dbcrash.py +++ b/test/functional/feature_dbcrash.py @@ -286,4 +286,4 @@ def run_test(self): if __name__ == "__main__": - ChainstateWriteCrashTest().main() + ChainstateWriteCrashTest(__file__).main() diff --git a/test/functional/feature_dersig.py b/test/functional/feature_dersig.py index 035e7151cad39..48b0b745c600f 100755 --- a/test/functional/feature_dersig.py +++ b/test/functional/feature_dersig.py @@ -148,4 +148,4 @@ def run_test(self): if __name__ == '__main__': - BIP66Test().main() + BIP66Test(__file__).main() diff --git a/test/functional/feature_dirsymlinks.py b/test/functional/feature_dirsymlinks.py index 96f4aed08a067..9fed99cbe58b7 100755 --- a/test/functional/feature_dirsymlinks.py +++ b/test/functional/feature_dirsymlinks.py @@ -38,4 +38,4 @@ def run_test(self): if __name__ == "__main__": - SymlinkTest().main() + SymlinkTest(__file__).main() diff --git a/test/functional/feature_discover.py b/test/functional/feature_discover.py index 7f4b81114edd6..9eaaea3652e4b 100755 --- a/test/functional/feature_discover.py +++ b/test/functional/feature_discover.py @@ -72,4 +72,4 @@ def run_test(self): if __name__ == '__main__': - DiscoverTest().main() + DiscoverTest(__file__).main() diff --git a/test/functional/feature_fastprune.py b/test/functional/feature_fastprune.py index c913c4f93af47..ca6877b9019ec 100755 --- a/test/functional/feature_fastprune.py +++ b/test/functional/feature_fastprune.py @@ -26,4 +26,4 @@ def run_test(self): if __name__ == '__main__': - FeatureFastpruneTest().main() + FeatureFastpruneTest(__file__).main() diff --git a/test/functional/feature_fee_estimation.py b/test/functional/feature_fee_estimation.py index ffc87f8b8bad0..34fb3c55737bb 100755 --- a/test/functional/feature_fee_estimation.py +++ b/test/functional/feature_fee_estimation.py @@ -439,4 +439,4 @@ def run_test(self): if __name__ == "__main__": - EstimateFeeTest().main() + EstimateFeeTest(__file__).main() diff --git a/test/functional/feature_filelock.py b/test/functional/feature_filelock.py index 567207915e84b..e71871114d390 100755 --- a/test/functional/feature_filelock.py +++ b/test/functional/feature_filelock.py @@ -54,4 +54,4 @@ def check_wallet_filelock(descriptors): check_wallet_filelock(True) if __name__ == '__main__': - FilelockTest().main() + FilelockTest(__file__).main() diff --git a/test/functional/feature_framework_miniwallet.py b/test/functional/feature_framework_miniwallet.py index f108289018376..1f381df236edf 100755 --- a/test/functional/feature_framework_miniwallet.py +++ b/test/functional/feature_framework_miniwallet.py @@ -46,4 +46,4 @@ def run_test(self): if __name__ == '__main__': - FeatureFrameworkMiniWalletTest().main() + FeatureFrameworkMiniWalletTest(__file__).main() diff --git a/test/functional/feature_help.py b/test/functional/feature_help.py index 4b66030b47b8a..6d8a742d89f5d 100755 --- a/test/functional/feature_help.py +++ b/test/functional/feature_help.py @@ -59,4 +59,4 @@ def run_test(self): if __name__ == '__main__': - HelpTest().main() + HelpTest(__file__).main() diff --git a/test/functional/feature_includeconf.py b/test/functional/feature_includeconf.py index 58ab063e71e39..ee484e7ec5064 100755 --- a/test/functional/feature_includeconf.py +++ b/test/functional/feature_includeconf.py @@ -83,4 +83,4 @@ def run_test(self): assert subversion.endswith("main; relative; relative2)/") if __name__ == '__main__': - IncludeConfTest().main() + IncludeConfTest(__file__).main() diff --git a/test/functional/feature_index_prune.py b/test/functional/feature_index_prune.py index 66c0a4f615f0b..030bf51ed8619 100755 --- a/test/functional/feature_index_prune.py +++ b/test/functional/feature_index_prune.py @@ -155,4 +155,4 @@ def run_test(self): if __name__ == '__main__': - FeatureIndexPruneTest().main() + FeatureIndexPruneTest(__file__).main() diff --git a/test/functional/feature_init.py b/test/functional/feature_init.py index 22ae0c307b79f..659d33684e5cd 100755 --- a/test/functional/feature_init.py +++ b/test/functional/feature_init.py @@ -149,4 +149,4 @@ def check_clean_start(): if __name__ == '__main__': - InitStressTest().main() + InitStressTest(__file__).main() diff --git a/test/functional/feature_loadblock.py b/test/functional/feature_loadblock.py index 5129e0d3287b1..1519c132b9895 100755 --- a/test/functional/feature_loadblock.py +++ b/test/functional/feature_loadblock.py @@ -80,4 +80,4 @@ def run_test(self): if __name__ == '__main__': - LoadblockTest().main() + LoadblockTest(__file__).main() diff --git a/test/functional/feature_logging.py b/test/functional/feature_logging.py index 0e9aca358d9eb..ab817fd12d218 100755 --- a/test/functional/feature_logging.py +++ b/test/functional/feature_logging.py @@ -101,4 +101,4 @@ def run_test(self): if __name__ == '__main__': - LoggingTest().main() + LoggingTest(__file__).main() diff --git a/test/functional/feature_maxtipage.py b/test/functional/feature_maxtipage.py index a1774a539534f..4ce9bb949c30e 100755 --- a/test/functional/feature_maxtipage.py +++ b/test/functional/feature_maxtipage.py @@ -62,4 +62,4 @@ def run_test(self): if __name__ == '__main__': - MaxTipAgeTest().main() + MaxTipAgeTest(__file__).main() diff --git a/test/functional/feature_maxuploadtarget.py b/test/functional/feature_maxuploadtarget.py index 39cff7b7382a0..136cdd024d5ed 100755 --- a/test/functional/feature_maxuploadtarget.py +++ b/test/functional/feature_maxuploadtarget.py @@ -206,4 +206,4 @@ def run_test(self): self.nodes[0].assert_start_raises_init_error(extra_args=["-maxuploadtarget=abc"], expected_msg="Error: Unable to parse -maxuploadtarget: 'abc'") if __name__ == '__main__': - MaxUploadTest().main() + MaxUploadTest(__file__).main() diff --git a/test/functional/feature_minchainwork.py b/test/functional/feature_minchainwork.py index 078d2ef63c9b8..8327a0477b38c 100755 --- a/test/functional/feature_minchainwork.py +++ b/test/functional/feature_minchainwork.py @@ -115,4 +115,4 @@ def run_test(self): if __name__ == '__main__': - MinimumChainWorkTest().main() + MinimumChainWorkTest(__file__).main() diff --git a/test/functional/feature_notifications.py b/test/functional/feature_notifications.py index d2b5315d31f9e..79e8df4b5e224 100755 --- a/test/functional/feature_notifications.py +++ b/test/functional/feature_notifications.py @@ -194,4 +194,4 @@ def expect_wallet_notify(self, tx_details): if __name__ == '__main__': - NotificationsTest().main() + NotificationsTest(__file__).main() diff --git a/test/functional/feature_nulldummy.py b/test/functional/feature_nulldummy.py index f896cb6f433fe..a53f78c13d8d9 100755 --- a/test/functional/feature_nulldummy.py +++ b/test/functional/feature_nulldummy.py @@ -154,4 +154,4 @@ def block_submit(self, node, txs, *, with_witness=False, accept): if __name__ == '__main__': - NULLDUMMYTest().main() + NULLDUMMYTest(__file__).main() diff --git a/test/functional/feature_posix_fs_permissions.py b/test/functional/feature_posix_fs_permissions.py index 40528779e6e3f..28b1803891362 100755 --- a/test/functional/feature_posix_fs_permissions.py +++ b/test/functional/feature_posix_fs_permissions.py @@ -40,4 +40,4 @@ def run_test(self): if __name__ == '__main__': - PosixFsPermissionsTest().main() + PosixFsPermissionsTest(__file__).main() diff --git a/test/functional/feature_presegwit_node_upgrade.py b/test/functional/feature_presegwit_node_upgrade.py index 3d762c8197765..8c1bd90083739 100755 --- a/test/functional/feature_presegwit_node_upgrade.py +++ b/test/functional/feature_presegwit_node_upgrade.py @@ -54,4 +54,4 @@ def run_test(self): if __name__ == '__main__': - SegwitUpgradeTest().main() + SegwitUpgradeTest(__file__).main() diff --git a/test/functional/feature_proxy.py b/test/functional/feature_proxy.py index 7a6f639021c67..2201821fda3cd 100755 --- a/test/functional/feature_proxy.py +++ b/test/functional/feature_proxy.py @@ -457,4 +457,4 @@ def networks_dict(d): os.unlink(socket_path) if __name__ == '__main__': - ProxyTest().main() + ProxyTest(__file__).main() diff --git a/test/functional/feature_pruning.py b/test/functional/feature_pruning.py index 5f99b8dee8c42..8d924282cfc58 100755 --- a/test/functional/feature_pruning.py +++ b/test/functional/feature_pruning.py @@ -513,4 +513,4 @@ def test_pruneheight_undo_presence(self): assert_equal(pruneheight, new_pruneheight) if __name__ == '__main__': - PruneTest().main() + PruneTest(__file__).main() diff --git a/test/functional/feature_rbf.py b/test/functional/feature_rbf.py index 739b9b9bb9548..cd5f5734c96e3 100755 --- a/test/functional/feature_rbf.py +++ b/test/functional/feature_rbf.py @@ -727,4 +727,4 @@ def test_fullrbf(self): assert conflicting_tx['txid'] in self.nodes[0].getrawmempool() if __name__ == '__main__': - ReplaceByFeeTest().main() + ReplaceByFeeTest(__file__).main() diff --git a/test/functional/feature_reindex.py b/test/functional/feature_reindex.py index 835cd0c5cfd8e..50a9ae1c060da 100755 --- a/test/functional/feature_reindex.py +++ b/test/functional/feature_reindex.py @@ -103,4 +103,4 @@ def run_test(self): if __name__ == '__main__': - ReindexTest().main() + ReindexTest(__file__).main() diff --git a/test/functional/feature_reindex_readonly.py b/test/functional/feature_reindex_readonly.py index 52c0bb26a6041..858a67566f98a 100755 --- a/test/functional/feature_reindex_readonly.py +++ b/test/functional/feature_reindex_readonly.py @@ -87,4 +87,4 @@ def run_test(self): if __name__ == '__main__': - BlockstoreReindexTest().main() + BlockstoreReindexTest(__file__).main() diff --git a/test/functional/feature_remove_pruned_files_on_startup.py b/test/functional/feature_remove_pruned_files_on_startup.py index 4ee653142acdb..2e689f29203db 100755 --- a/test/functional/feature_remove_pruned_files_on_startup.py +++ b/test/functional/feature_remove_pruned_files_on_startup.py @@ -52,4 +52,4 @@ def run_test(self): assert not os.path.exists(rev1) if __name__ == '__main__': - FeatureRemovePrunedFilesOnStartupTest().main() + FeatureRemovePrunedFilesOnStartupTest(__file__).main() diff --git a/test/functional/feature_segwit.py b/test/functional/feature_segwit.py index 4dc19222c4b37..f98f326e8f441 100755 --- a/test/functional/feature_segwit.py +++ b/test/functional/feature_segwit.py @@ -657,4 +657,4 @@ def create_and_mine_tx_from_txids(self, txids, success=True): if __name__ == '__main__': - SegWitTest().main() + SegWitTest(__file__).main() diff --git a/test/functional/feature_settings.py b/test/functional/feature_settings.py index 1cd0aeabd3265..2189eac7ddec6 100755 --- a/test/functional/feature_settings.py +++ b/test/functional/feature_settings.py @@ -88,4 +88,4 @@ def run_test(self): if __name__ == '__main__': - SettingsTest().main() + SettingsTest(__file__).main() diff --git a/test/functional/feature_shutdown.py b/test/functional/feature_shutdown.py index 291df4c518a94..a7277be39da1a 100755 --- a/test/functional/feature_shutdown.py +++ b/test/functional/feature_shutdown.py @@ -32,4 +32,4 @@ def run_test(self): self.stop_node(0, wait=1000) if __name__ == '__main__': - ShutdownTest().main() + ShutdownTest(__file__).main() diff --git a/test/functional/feature_signet.py b/test/functional/feature_signet.py index a90a2a8e5e989..b648266caebe2 100755 --- a/test/functional/feature_signet.py +++ b/test/functional/feature_signet.py @@ -82,4 +82,4 @@ def run_test(self): if __name__ == '__main__': - SignetBasicTest().main() + SignetBasicTest(__file__).main() diff --git a/test/functional/feature_startupnotify.py b/test/functional/feature_startupnotify.py index a8e62c6244dca..1e071037254d5 100755 --- a/test/functional/feature_startupnotify.py +++ b/test/functional/feature_startupnotify.py @@ -39,4 +39,4 @@ def get_count(): if __name__ == '__main__': - StartupNotifyTest().main() + StartupNotifyTest(__file__).main() diff --git a/test/functional/feature_taproot.py b/test/functional/feature_taproot.py index 1a0844d240821..b2e030adc7daa 100755 --- a/test/functional/feature_taproot.py +++ b/test/functional/feature_taproot.py @@ -1766,4 +1766,4 @@ def run_test(self): if __name__ == '__main__': - TaprootTest().main() + TaprootTest(__file__).main() diff --git a/test/functional/feature_uacomment.py b/test/functional/feature_uacomment.py index 4720f6dea3968..fc372f543d6e7 100755 --- a/test/functional/feature_uacomment.py +++ b/test/functional/feature_uacomment.py @@ -37,4 +37,4 @@ def run_test(self): if __name__ == '__main__': - UacommentTest().main() + UacommentTest(__file__).main() diff --git a/test/functional/feature_unsupported_utxo_db.py b/test/functional/feature_unsupported_utxo_db.py index 6acf551216559..694a8e0623eb1 100755 --- a/test/functional/feature_unsupported_utxo_db.py +++ b/test/functional/feature_unsupported_utxo_db.py @@ -58,4 +58,4 @@ def run_test(self): if __name__ == "__main__": - UnsupportedUtxoDbTest().main() + UnsupportedUtxoDbTest(__file__).main() diff --git a/test/functional/feature_utxo_set_hash.py b/test/functional/feature_utxo_set_hash.py index 0bdcc6d83d5d5..3ab779b87dc82 100755 --- a/test/functional/feature_utxo_set_hash.py +++ b/test/functional/feature_utxo_set_hash.py @@ -75,4 +75,4 @@ def run_test(self): if __name__ == '__main__': - UTXOSetHashTest().main() + UTXOSetHashTest(__file__).main() diff --git a/test/functional/feature_versionbits_warning.py b/test/functional/feature_versionbits_warning.py index 2c330eb6817dd..dc25ce6c83681 100755 --- a/test/functional/feature_versionbits_warning.py +++ b/test/functional/feature_versionbits_warning.py @@ -100,4 +100,4 @@ def run_test(self): self.wait_until(lambda: self.versionbits_in_alert_file()) if __name__ == '__main__': - VersionBitsWarningTest().main() + VersionBitsWarningTest(__file__).main() diff --git a/test/functional/interface_bitcoin_cli.py b/test/functional/interface_bitcoin_cli.py index a6628dcbf3f88..e7113f8335d5b 100755 --- a/test/functional/interface_bitcoin_cli.py +++ b/test/functional/interface_bitcoin_cli.py @@ -383,4 +383,4 @@ def run_test(self): if __name__ == '__main__': - TestBitcoinCli().main() + TestBitcoinCli(__file__).main() diff --git a/test/functional/interface_http.py b/test/functional/interface_http.py index 6e32009e0516a..dbdceb52d15aa 100755 --- a/test/functional/interface_http.py +++ b/test/functional/interface_http.py @@ -106,4 +106,4 @@ def run_test(self): if __name__ == '__main__': - HTTPBasicsTest ().main () + HTTPBasicsTest(__file__).main() diff --git a/test/functional/interface_rest.py b/test/functional/interface_rest.py index ae8d6b226db81..5706b1427b36c 100755 --- a/test/functional/interface_rest.py +++ b/test/functional/interface_rest.py @@ -436,4 +436,4 @@ def run_test(self): assert_equal(resp.read().decode('utf-8').rstrip(), f"Invalid hash: {INVALID_PARAM}") if __name__ == '__main__': - RESTTest().main() + RESTTest(__file__).main() diff --git a/test/functional/interface_rpc.py b/test/functional/interface_rpc.py index 6c1855c400487..9074f0a2d9e11 100755 --- a/test/functional/interface_rpc.py +++ b/test/functional/interface_rpc.py @@ -246,4 +246,4 @@ def run_test(self): if __name__ == '__main__': - RPCInterfaceTest().main() + RPCInterfaceTest(__file__).main() diff --git a/test/functional/interface_usdt_coinselection.py b/test/functional/interface_usdt_coinselection.py index 30931a41cd252..dc40986a75dc9 100755 --- a/test/functional/interface_usdt_coinselection.py +++ b/test/functional/interface_usdt_coinselection.py @@ -231,4 +231,4 @@ def run_test(self): if __name__ == '__main__': - CoinSelectionTracepointTest().main() + CoinSelectionTracepointTest(__file__).main() diff --git a/test/functional/interface_usdt_mempool.py b/test/functional/interface_usdt_mempool.py index 0168d9f916a4c..a08827866569b 100755 --- a/test/functional/interface_usdt_mempool.py +++ b/test/functional/interface_usdt_mempool.py @@ -322,4 +322,4 @@ def run_test(self): if __name__ == "__main__": - MempoolTracepointTest().main() + MempoolTracepointTest(__file__).main() diff --git a/test/functional/interface_usdt_net.py b/test/functional/interface_usdt_net.py index 5d7c8c23041fc..7b55259b63a88 100755 --- a/test/functional/interface_usdt_net.py +++ b/test/functional/interface_usdt_net.py @@ -168,4 +168,4 @@ def handle_outbound(_, data, __): if __name__ == '__main__': - NetTracepointTest().main() + NetTracepointTest(__file__).main() diff --git a/test/functional/interface_usdt_utxocache.py b/test/functional/interface_usdt_utxocache.py index 06cdcd10a04bc..ad98a3a16287d 100755 --- a/test/functional/interface_usdt_utxocache.py +++ b/test/functional/interface_usdt_utxocache.py @@ -407,4 +407,4 @@ def handle_utxocache_flush(_, data, __): if __name__ == '__main__': - UTXOCacheTracepointTest().main() + UTXOCacheTracepointTest(__file__).main() diff --git a/test/functional/interface_usdt_validation.py b/test/functional/interface_usdt_validation.py index 30982393d85b9..9a37b96ada874 100755 --- a/test/functional/interface_usdt_validation.py +++ b/test/functional/interface_usdt_validation.py @@ -131,4 +131,4 @@ def handle_blockconnected(_, data, __): if __name__ == '__main__': - ValidationTracepointTest().main() + ValidationTracepointTest(__file__).main() diff --git a/test/functional/interface_zmq.py b/test/functional/interface_zmq.py index 9f6f8919de85f..b960f40ccc702 100755 --- a/test/functional/interface_zmq.py +++ b/test/functional/interface_zmq.py @@ -597,4 +597,4 @@ def test_ipv6(self): if __name__ == '__main__': - ZMQTest().main() + ZMQTest(__file__).main() diff --git a/test/functional/mempool_accept.py b/test/functional/mempool_accept.py index e1cee46839ce1..2b841f3791e4d 100755 --- a/test/functional/mempool_accept.py +++ b/test/functional/mempool_accept.py @@ -409,4 +409,4 @@ def run_test(self): ) if __name__ == '__main__': - MempoolAcceptanceTest().main() + MempoolAcceptanceTest(__file__).main() diff --git a/test/functional/mempool_accept_wtxid.py b/test/functional/mempool_accept_wtxid.py index 4767d6db22c66..e00e7b1ae4b81 100755 --- a/test/functional/mempool_accept_wtxid.py +++ b/test/functional/mempool_accept_wtxid.py @@ -125,4 +125,4 @@ def run_test(self): assert_equal(node.getmempoolinfo()["unbroadcastcount"], 0) if __name__ == '__main__': - MempoolWtxidTest().main() + MempoolWtxidTest(__file__).main() diff --git a/test/functional/mempool_compatibility.py b/test/functional/mempool_compatibility.py index a126f164aabe2..7c72aaae77372 100755 --- a/test/functional/mempool_compatibility.py +++ b/test/functional/mempool_compatibility.py @@ -78,4 +78,4 @@ def run_test(self): if __name__ == "__main__": - MempoolCompatibilityTest().main() + MempoolCompatibilityTest(__file__).main() diff --git a/test/functional/mempool_datacarrier.py b/test/functional/mempool_datacarrier.py index 2e27aa988ea0e..ed6ad8461a138 100755 --- a/test/functional/mempool_datacarrier.py +++ b/test/functional/mempool_datacarrier.py @@ -88,4 +88,4 @@ def run_test(self): if __name__ == '__main__': - DataCarrierTest().main() + DataCarrierTest(__file__).main() diff --git a/test/functional/mempool_dust.py b/test/functional/mempool_dust.py index e0c026207ae28..1ea03a8a9ec91 100755 --- a/test/functional/mempool_dust.py +++ b/test/functional/mempool_dust.py @@ -110,4 +110,4 @@ def run_test(self): if __name__ == '__main__': - DustRelayFeeTest().main() + DustRelayFeeTest(__file__).main() diff --git a/test/functional/mempool_expiry.py b/test/functional/mempool_expiry.py index 5eebe43488af9..2bd88f982549b 100755 --- a/test/functional/mempool_expiry.py +++ b/test/functional/mempool_expiry.py @@ -114,4 +114,4 @@ def run_test(self): if __name__ == '__main__': - MempoolExpiryTest().main() + MempoolExpiryTest(__file__).main() diff --git a/test/functional/mempool_limit.py b/test/functional/mempool_limit.py index 49a0a32c450d9..626928a49a90c 100755 --- a/test/functional/mempool_limit.py +++ b/test/functional/mempool_limit.py @@ -342,4 +342,4 @@ def run_test(self): if __name__ == '__main__': - MempoolLimitTest().main() + MempoolLimitTest(__file__).main() diff --git a/test/functional/mempool_package_limits.py b/test/functional/mempool_package_limits.py index 2a64597511727..6e26a684e22ec 100755 --- a/test/functional/mempool_package_limits.py +++ b/test/functional/mempool_package_limits.py @@ -343,4 +343,4 @@ def test_desc_size_limits(self): if __name__ == "__main__": - MempoolPackageLimitsTest().main() + MempoolPackageLimitsTest(__file__).main() diff --git a/test/functional/mempool_package_onemore.py b/test/functional/mempool_package_onemore.py index 632425814a819..fd54a8c3e1caf 100755 --- a/test/functional/mempool_package_onemore.py +++ b/test/functional/mempool_package_onemore.py @@ -77,4 +77,4 @@ def run_test(self): if __name__ == '__main__': - MempoolPackagesTest().main() + MempoolPackagesTest(__file__).main() diff --git a/test/functional/mempool_package_rbf.py b/test/functional/mempool_package_rbf.py index e9658aa8d02c0..9b4269f0a0e47 100755 --- a/test/functional/mempool_package_rbf.py +++ b/test/functional/mempool_package_rbf.py @@ -596,4 +596,4 @@ def test_child_conflicts_parent_mempool_ancestor(self): assert child_result["txid"] not in mempool_info if __name__ == "__main__": - PackageRBFTest().main() + PackageRBFTest(__file__).main() diff --git a/test/functional/mempool_packages.py b/test/functional/mempool_packages.py index 4be6594de628c..a844a2a1d8f85 100755 --- a/test/functional/mempool_packages.py +++ b/test/functional/mempool_packages.py @@ -298,4 +298,4 @@ def run_test(self): self.sync_blocks() if __name__ == '__main__': - MempoolPackagesTest().main() + MempoolPackagesTest(__file__).main() diff --git a/test/functional/mempool_persist.py b/test/functional/mempool_persist.py index 32a927084aa69..c64c203e50494 100755 --- a/test/functional/mempool_persist.py +++ b/test/functional/mempool_persist.py @@ -263,4 +263,4 @@ def test_importmempool_union(self): if __name__ == "__main__": - MempoolPersistTest().main() + MempoolPersistTest(__file__).main() diff --git a/test/functional/mempool_reorg.py b/test/functional/mempool_reorg.py index 691518ea0981a..e27942760ccfa 100755 --- a/test/functional/mempool_reorg.py +++ b/test/functional/mempool_reorg.py @@ -194,4 +194,4 @@ def run_test(self): if __name__ == '__main__': - MempoolCoinbaseTest().main() + MempoolCoinbaseTest(__file__).main() diff --git a/test/functional/mempool_resurrect.py b/test/functional/mempool_resurrect.py index c10052372d3a2..720255b9e3419 100755 --- a/test/functional/mempool_resurrect.py +++ b/test/functional/mempool_resurrect.py @@ -55,4 +55,4 @@ def run_test(self): if __name__ == '__main__': - MempoolCoinbaseTest().main() + MempoolCoinbaseTest(__file__).main() diff --git a/test/functional/mempool_sigoplimit.py b/test/functional/mempool_sigoplimit.py index d3fb5f91191cf..4656176a75975 100755 --- a/test/functional/mempool_sigoplimit.py +++ b/test/functional/mempool_sigoplimit.py @@ -196,4 +196,4 @@ def run_test(self): if __name__ == '__main__': - BytesPerSigOpTest().main() + BytesPerSigOpTest(__file__).main() diff --git a/test/functional/mempool_spend_coinbase.py b/test/functional/mempool_spend_coinbase.py index a7cb2ba60212d..64ab33d3ffd4d 100755 --- a/test/functional/mempool_spend_coinbase.py +++ b/test/functional/mempool_spend_coinbase.py @@ -57,4 +57,4 @@ def run_test(self): if __name__ == '__main__': - MempoolSpendCoinbaseTest().main() + MempoolSpendCoinbaseTest(__file__).main() diff --git a/test/functional/mempool_truc.py b/test/functional/mempool_truc.py index e1f3d77201616..3f57b3e356e34 100755 --- a/test/functional/mempool_truc.py +++ b/test/functional/mempool_truc.py @@ -644,4 +644,4 @@ def run_test(self): if __name__ == "__main__": - MempoolTRUC().main() + MempoolTRUC(__file__).main() diff --git a/test/functional/mempool_unbroadcast.py b/test/functional/mempool_unbroadcast.py index 12de750731417..7c96b4b570d4b 100755 --- a/test/functional/mempool_unbroadcast.py +++ b/test/functional/mempool_unbroadcast.py @@ -109,4 +109,4 @@ def test_txn_removal(self): if __name__ == "__main__": - MempoolUnbroadcastTest().main() + MempoolUnbroadcastTest(__file__).main() diff --git a/test/functional/mempool_updatefromblock.py b/test/functional/mempool_updatefromblock.py index 8350e9c91ec9c..1754991756a91 100755 --- a/test/functional/mempool_updatefromblock.py +++ b/test/functional/mempool_updatefromblock.py @@ -103,4 +103,4 @@ def run_test(self): if __name__ == '__main__': - MempoolUpdateFromBlockTest().main() + MempoolUpdateFromBlockTest(__file__).main() diff --git a/test/functional/mining_basic.py b/test/functional/mining_basic.py index 5f2dde8eacacf..6a364a481599e 100755 --- a/test/functional/mining_basic.py +++ b/test/functional/mining_basic.py @@ -325,4 +325,4 @@ def chain_tip(b_hash, *, status='headers-only', branchlen=1): if __name__ == '__main__': - MiningTest().main() + MiningTest(__file__).main() diff --git a/test/functional/mining_getblocktemplate_longpoll.py b/test/functional/mining_getblocktemplate_longpoll.py index c0e7195c8220e..2d15151e6508e 100755 --- a/test/functional/mining_getblocktemplate_longpoll.py +++ b/test/functional/mining_getblocktemplate_longpoll.py @@ -73,4 +73,4 @@ def run_test(self): assert not thr.is_alive() if __name__ == '__main__': - GetBlockTemplateLPTest().main() + GetBlockTemplateLPTest(__file__).main() diff --git a/test/functional/mining_prioritisetransaction.py b/test/functional/mining_prioritisetransaction.py index c5f34e3ecbfcd..eb55202e1604f 100755 --- a/test/functional/mining_prioritisetransaction.py +++ b/test/functional/mining_prioritisetransaction.py @@ -305,4 +305,4 @@ def run_test(self): assert template != new_template if __name__ == '__main__': - PrioritiseTransactionTest().main() + PrioritiseTransactionTest(__file__).main() diff --git a/test/functional/p2p_1p1c_network.py b/test/functional/p2p_1p1c_network.py index ea59248506779..c3cdb3e0b319d 100755 --- a/test/functional/p2p_1p1c_network.py +++ b/test/functional/p2p_1p1c_network.py @@ -163,4 +163,4 @@ def run_test(self): if __name__ == '__main__': - PackageRelayTest().main() + PackageRelayTest(__file__).main() diff --git a/test/functional/p2p_add_connections.py b/test/functional/p2p_add_connections.py index bd766a279efd2..886de36fccfd5 100755 --- a/test/functional/p2p_add_connections.py +++ b/test/functional/p2p_add_connections.py @@ -107,4 +107,4 @@ def run_test(self): assert_equal(feeler_conn.last_message["version"].relay, 0) if __name__ == '__main__': - P2PAddConnections().main() + P2PAddConnections(__file__).main() diff --git a/test/functional/p2p_addr_relay.py b/test/functional/p2p_addr_relay.py index d10e47e0367ac..56a9e6a84e120 100755 --- a/test/functional/p2p_addr_relay.py +++ b/test/functional/p2p_addr_relay.py @@ -441,4 +441,4 @@ def destination_rotates_more_than_once_over_several_days_test(self): if __name__ == '__main__': - AddrTest().main() + AddrTest(__file__).main() diff --git a/test/functional/p2p_addrfetch.py b/test/functional/p2p_addrfetch.py index 3ead653ba693a..69cc106341d1b 100755 --- a/test/functional/p2p_addrfetch.py +++ b/test/functional/p2p_addrfetch.py @@ -83,4 +83,4 @@ def run_test(self): if __name__ == '__main__': - P2PAddrFetch().main() + P2PAddrFetch(__file__).main() diff --git a/test/functional/p2p_addrv2_relay.py b/test/functional/p2p_addrv2_relay.py index 4ec8e0bc0433d..d5ded926d36ac 100755 --- a/test/functional/p2p_addrv2_relay.py +++ b/test/functional/p2p_addrv2_relay.py @@ -110,4 +110,4 @@ def run_test(self): if __name__ == '__main__': - AddrTest().main() + AddrTest(__file__).main() diff --git a/test/functional/p2p_block_sync.py b/test/functional/p2p_block_sync.py index 6c7f08364e3d2..51bbac173873c 100755 --- a/test/functional/p2p_block_sync.py +++ b/test/functional/p2p_block_sync.py @@ -34,4 +34,4 @@ def run_test(self): if __name__ == '__main__': - BlockSyncTest().main() + BlockSyncTest(__file__).main() diff --git a/test/functional/p2p_blockfilters.py b/test/functional/p2p_blockfilters.py index 680fa9c7faf11..88d5aa1408c9c 100755 --- a/test/functional/p2p_blockfilters.py +++ b/test/functional/p2p_blockfilters.py @@ -282,4 +282,4 @@ def compute_last_header(prev_header, hashes): if __name__ == '__main__': - CompactFiltersTest().main() + CompactFiltersTest(__file__).main() diff --git a/test/functional/p2p_blocksonly.py b/test/functional/p2p_blocksonly.py index 637644e6e44f0..b9e6dc90563cb 100755 --- a/test/functional/p2p_blocksonly.py +++ b/test/functional/p2p_blocksonly.py @@ -125,4 +125,4 @@ def check_p2p_tx_violation(self): if __name__ == '__main__': - P2PBlocksOnly().main() + P2PBlocksOnly(__file__).main() diff --git a/test/functional/p2p_compactblocks.py b/test/functional/p2p_compactblocks.py index 9e314db1108ad..49cf26d425c13 100755 --- a/test/functional/p2p_compactblocks.py +++ b/test/functional/p2p_compactblocks.py @@ -965,4 +965,4 @@ def run_test(self): if __name__ == '__main__': - CompactBlocksTest().main() + CompactBlocksTest(__file__).main() diff --git a/test/functional/p2p_compactblocks_blocksonly.py b/test/functional/p2p_compactblocks_blocksonly.py index 761cd3a218147..b92efc875ca68 100755 --- a/test/functional/p2p_compactblocks_blocksonly.py +++ b/test/functional/p2p_compactblocks_blocksonly.py @@ -127,4 +127,4 @@ def test_for_cmpctblock(block): p2p_conn_blocksonly.wait_until(lambda: test_for_cmpctblock(block2)) if __name__ == '__main__': - P2PCompactBlocksBlocksOnly().main() + P2PCompactBlocksBlocksOnly(__file__).main() diff --git a/test/functional/p2p_compactblocks_hb.py b/test/functional/p2p_compactblocks_hb.py index 023b33ff6d793..e4f58e9cf7cc0 100755 --- a/test/functional/p2p_compactblocks_hb.py +++ b/test/functional/p2p_compactblocks_hb.py @@ -97,4 +97,4 @@ def run_test(self): if __name__ == '__main__': - CompactBlocksConnectionTest().main() + CompactBlocksConnectionTest(__file__).main() diff --git a/test/functional/p2p_disconnect_ban.py b/test/functional/p2p_disconnect_ban.py index e47f9c732bfee..94be86475ead8 100755 --- a/test/functional/p2p_disconnect_ban.py +++ b/test/functional/p2p_disconnect_ban.py @@ -147,4 +147,4 @@ def run_test(self): assert not [node for node in self.nodes[0].getpeerinfo() if node['id'] == id1] if __name__ == '__main__': - DisconnectBanTest().main() + DisconnectBanTest(__file__).main() diff --git a/test/functional/p2p_dns_seeds.py b/test/functional/p2p_dns_seeds.py index e58ad8e0fc811..a2d4ea110f720 100755 --- a/test/functional/p2p_dns_seeds.py +++ b/test/functional/p2p_dns_seeds.py @@ -126,4 +126,4 @@ def wait_time_tests(self): if __name__ == '__main__': - P2PDNSSeeds().main() + P2PDNSSeeds(__file__).main() diff --git a/test/functional/p2p_dos_header_tree.py b/test/functional/p2p_dos_header_tree.py index 4b4346af4911d..fbb5d716f5bf0 100755 --- a/test/functional/p2p_dos_header_tree.py +++ b/test/functional/p2p_dos_header_tree.py @@ -85,4 +85,4 @@ def run_test(self): if __name__ == '__main__': - RejectLowDifficultyHeadersTest().main() + RejectLowDifficultyHeadersTest(__file__).main() diff --git a/test/functional/p2p_eviction.py b/test/functional/p2p_eviction.py index 8b31dfa549ef2..0d2bdcc429c07 100755 --- a/test/functional/p2p_eviction.py +++ b/test/functional/p2p_eviction.py @@ -124,4 +124,4 @@ def run_test(self): if __name__ == '__main__': - P2PEvict().main() + P2PEvict(__file__).main() diff --git a/test/functional/p2p_feefilter.py b/test/functional/p2p_feefilter.py index bcba534f9a541..6b44118467802 100755 --- a/test/functional/p2p_feefilter.py +++ b/test/functional/p2p_feefilter.py @@ -132,4 +132,4 @@ def test_feefilter_blocksonly(self): if __name__ == '__main__': - FeeFilterTest().main() + FeeFilterTest(__file__).main() diff --git a/test/functional/p2p_filter.py b/test/functional/p2p_filter.py index 7c8ed58e51c73..e4aaf507cf347 100755 --- a/test/functional/p2p_filter.py +++ b/test/functional/p2p_filter.py @@ -252,4 +252,4 @@ def run_test(self): if __name__ == '__main__': - FilterTest().main() + FilterTest(__file__).main() diff --git a/test/functional/p2p_fingerprint.py b/test/functional/p2p_fingerprint.py index e8bba8555fcf3..f49be62056de4 100755 --- a/test/functional/p2p_fingerprint.py +++ b/test/functional/p2p_fingerprint.py @@ -130,4 +130,4 @@ def run_test(self): if __name__ == '__main__': - P2PFingerprintTest().main() + P2PFingerprintTest(__file__).main() diff --git a/test/functional/p2p_getaddr_caching.py b/test/functional/p2p_getaddr_caching.py index 60b43c32ae652..6626b14ee0f18 100755 --- a/test/functional/p2p_getaddr_caching.py +++ b/test/functional/p2p_getaddr_caching.py @@ -119,4 +119,4 @@ def run_test(self): if __name__ == '__main__': - AddrTest().main() + AddrTest(__file__).main() diff --git a/test/functional/p2p_getdata.py b/test/functional/p2p_getdata.py index 89d68d5ba07d3..6153d08d9b4ff 100755 --- a/test/functional/p2p_getdata.py +++ b/test/functional/p2p_getdata.py @@ -46,4 +46,4 @@ def run_test(self): if __name__ == '__main__': - GetdataTest().main() + GetdataTest(__file__).main() diff --git a/test/functional/p2p_handshake.py b/test/functional/p2p_handshake.py index 9536e748931ad..18307a2824777 100755 --- a/test/functional/p2p_handshake.py +++ b/test/functional/p2p_handshake.py @@ -97,4 +97,4 @@ def run_test(self): if __name__ == '__main__': - P2PHandshakeTest().main() + P2PHandshakeTest(__file__).main() diff --git a/test/functional/p2p_headers_sync_with_minchainwork.py b/test/functional/p2p_headers_sync_with_minchainwork.py index 832fd7e0e9543..9055232cf316a 100755 --- a/test/functional/p2p_headers_sync_with_minchainwork.py +++ b/test/functional/p2p_headers_sync_with_minchainwork.py @@ -162,4 +162,4 @@ def run_test(self): if __name__ == '__main__': - RejectLowDifficultyHeadersTest().main() + RejectLowDifficultyHeadersTest(__file__).main() diff --git a/test/functional/p2p_i2p_ports.py b/test/functional/p2p_i2p_ports.py index 20dcb50a5749c..b1a3c61c7a31c 100755 --- a/test/functional/p2p_i2p_ports.py +++ b/test/functional/p2p_i2p_ports.py @@ -32,4 +32,4 @@ def run_test(self): if __name__ == '__main__': - I2PPorts().main() + I2PPorts(__file__).main() diff --git a/test/functional/p2p_i2p_sessions.py b/test/functional/p2p_i2p_sessions.py index 9e7fdc6e1446a..67474f6c0ea30 100755 --- a/test/functional/p2p_i2p_sessions.py +++ b/test/functional/p2p_i2p_sessions.py @@ -33,4 +33,4 @@ def run_test(self): if __name__ == '__main__': - I2PSessions().main() + I2PSessions(__file__).main() diff --git a/test/functional/p2p_ibd_stalling.py b/test/functional/p2p_ibd_stalling.py index 830f374d6322b..11cd8837f463d 100755 --- a/test/functional/p2p_ibd_stalling.py +++ b/test/functional/p2p_ibd_stalling.py @@ -162,4 +162,4 @@ def is_block_requested(self, peers, hash): if __name__ == '__main__': - P2PIBDStallingTest().main() + P2PIBDStallingTest(__file__).main() diff --git a/test/functional/p2p_ibd_txrelay.py b/test/functional/p2p_ibd_txrelay.py index b93e39a9250a6..882f5b5c134a4 100755 --- a/test/functional/p2p_ibd_txrelay.py +++ b/test/functional/p2p_ibd_txrelay.py @@ -86,4 +86,4 @@ def run_test(self): peer_txer.send_and_ping(msg_tx(tx)) if __name__ == '__main__': - P2PIBDTxRelayTest().main() + P2PIBDTxRelayTest(__file__).main() diff --git a/test/functional/p2p_initial_headers_sync.py b/test/functional/p2p_initial_headers_sync.py index bc6e0fb3555b4..5c17b7567701b 100755 --- a/test/functional/p2p_initial_headers_sync.py +++ b/test/functional/p2p_initial_headers_sync.py @@ -96,5 +96,5 @@ def run_test(self): self.log.info("Success!") if __name__ == '__main__': - HeadersSyncTest().main() + HeadersSyncTest(__file__).main() diff --git a/test/functional/p2p_invalid_block.py b/test/functional/p2p_invalid_block.py index 8ec62ae5eefe2..c4c79dcbb8787 100755 --- a/test/functional/p2p_invalid_block.py +++ b/test/functional/p2p_invalid_block.py @@ -138,4 +138,4 @@ def run_test(self): if __name__ == '__main__': - InvalidBlockRequestTest().main() + InvalidBlockRequestTest(__file__).main() diff --git a/test/functional/p2p_invalid_locator.py b/test/functional/p2p_invalid_locator.py index 32a23532a23ab..bde01d5c95d42 100755 --- a/test/functional/p2p_invalid_locator.py +++ b/test/functional/p2p_invalid_locator.py @@ -39,4 +39,4 @@ def run_test(self): if __name__ == '__main__': - InvalidLocatorTest().main() + InvalidLocatorTest(__file__).main() diff --git a/test/functional/p2p_invalid_messages.py b/test/functional/p2p_invalid_messages.py index 8e459ba676e76..507393fb7074d 100755 --- a/test/functional/p2p_invalid_messages.py +++ b/test/functional/p2p_invalid_messages.py @@ -356,4 +356,4 @@ def test_resource_exhaustion(self): if __name__ == '__main__': - InvalidMessagesTest().main() + InvalidMessagesTest(__file__).main() diff --git a/test/functional/p2p_invalid_tx.py b/test/functional/p2p_invalid_tx.py index 0ae05d4b0badf..241aefab24526 100755 --- a/test/functional/p2p_invalid_tx.py +++ b/test/functional/p2p_invalid_tx.py @@ -224,4 +224,4 @@ def run_test(self): if __name__ == '__main__': - InvalidTxRequestTest().main() + InvalidTxRequestTest(__file__).main() diff --git a/test/functional/p2p_leak.py b/test/functional/p2p_leak.py index 645488f24d95f..f800e815d8d63 100755 --- a/test/functional/p2p_leak.py +++ b/test/functional/p2p_leak.py @@ -178,4 +178,4 @@ def run_test(self): if __name__ == '__main__': - P2PLeakTest().main() + P2PLeakTest(__file__).main() diff --git a/test/functional/p2p_leak_tx.py b/test/functional/p2p_leak_tx.py index f53f98e06d169..a2eec49b7273f 100755 --- a/test/functional/p2p_leak_tx.py +++ b/test/functional/p2p_leak_tx.py @@ -104,4 +104,4 @@ def test_notfound_on_unannounced_tx(self): if __name__ == '__main__': - P2PLeakTxTest().main() + P2PLeakTxTest(__file__).main() diff --git a/test/functional/p2p_message_capture.py b/test/functional/p2p_message_capture.py index 691a0b6409c80..4c82adc58c97d 100755 --- a/test/functional/p2p_message_capture.py +++ b/test/functional/p2p_message_capture.py @@ -69,4 +69,4 @@ def run_test(self): if __name__ == '__main__': - MessageCaptureTest().main() + MessageCaptureTest(__file__).main() diff --git a/test/functional/p2p_mutated_blocks.py b/test/functional/p2p_mutated_blocks.py index 708b19b1e591d..4a790168dad2d 100755 --- a/test/functional/p2p_mutated_blocks.py +++ b/test/functional/p2p_mutated_blocks.py @@ -112,4 +112,4 @@ def self_transfer_requested(): if __name__ == '__main__': - MutatedBlocksTest().main() + MutatedBlocksTest(__file__).main() diff --git a/test/functional/p2p_net_deadlock.py b/test/functional/p2p_net_deadlock.py index 1a357b944b675..4f1b731e2188c 100755 --- a/test/functional/p2p_net_deadlock.py +++ b/test/functional/p2p_net_deadlock.py @@ -34,4 +34,4 @@ def run_test(self): if __name__ == '__main__': - NetDeadlockTest().main() + NetDeadlockTest(__file__).main() diff --git a/test/functional/p2p_nobloomfilter_messages.py b/test/functional/p2p_nobloomfilter_messages.py index 507a71b2a91d5..dd2dc9ae69ab0 100755 --- a/test/functional/p2p_nobloomfilter_messages.py +++ b/test/functional/p2p_nobloomfilter_messages.py @@ -45,4 +45,4 @@ def run_test(self): if __name__ == '__main__': - P2PNoBloomFilterMessages().main() + P2PNoBloomFilterMessages(__file__).main() diff --git a/test/functional/p2p_node_network_limited.py b/test/functional/p2p_node_network_limited.py index 8b63d8ee26d06..df6e6a2e28aac 100755 --- a/test/functional/p2p_node_network_limited.py +++ b/test/functional/p2p_node_network_limited.py @@ -172,4 +172,4 @@ def run_test(self): self.test_avoid_requesting_historical_blocks() if __name__ == '__main__': - NodeNetworkLimitedTest().main() + NodeNetworkLimitedTest(__file__).main() diff --git a/test/functional/p2p_opportunistic_1p1c.py b/test/functional/p2p_opportunistic_1p1c.py index aec6e95fbcfa8..4477046c8d6d1 100755 --- a/test/functional/p2p_opportunistic_1p1c.py +++ b/test/functional/p2p_opportunistic_1p1c.py @@ -412,4 +412,4 @@ def run_test(self): if __name__ == '__main__': - PackageRelayTest().main() + PackageRelayTest(__file__).main() diff --git a/test/functional/p2p_orphan_handling.py b/test/functional/p2p_orphan_handling.py index f525d87cca048..22600bf8a4e92 100755 --- a/test/functional/p2p_orphan_handling.py +++ b/test/functional/p2p_orphan_handling.py @@ -585,4 +585,4 @@ def run_test(self): if __name__ == '__main__': - OrphanHandlingTest().main() + OrphanHandlingTest(__file__).main() diff --git a/test/functional/p2p_outbound_eviction.py b/test/functional/p2p_outbound_eviction.py index 8d8968899900e..30ac85e32f316 100755 --- a/test/functional/p2p_outbound_eviction.py +++ b/test/functional/p2p_outbound_eviction.py @@ -250,4 +250,4 @@ def run_test(self): if __name__ == '__main__': - P2POutEvict().main() + P2POutEvict(__file__).main() diff --git a/test/functional/p2p_permissions.py b/test/functional/p2p_permissions.py index 80a27943fdfdc..5ca5101613251 100755 --- a/test/functional/p2p_permissions.py +++ b/test/functional/p2p_permissions.py @@ -147,4 +147,4 @@ def checkpermission(self, args, expectedPermissions): if __name__ == '__main__': - P2PPermissionsTests().main() + P2PPermissionsTests(__file__).main() diff --git a/test/functional/p2p_ping.py b/test/functional/p2p_ping.py index 3ba30a42b1aff..5c10ac2a4bec4 100755 --- a/test/functional/p2p_ping.py +++ b/test/functional/p2p_ping.py @@ -117,4 +117,4 @@ def run_test(self): if __name__ == '__main__': - PingPongTest().main() + PingPongTest(__file__).main() diff --git a/test/functional/p2p_segwit.py b/test/functional/p2p_segwit.py index d20cf41a72c99..9be53d2ab8b61 100755 --- a/test/functional/p2p_segwit.py +++ b/test/functional/p2p_segwit.py @@ -2067,4 +2067,4 @@ def received_wtxidrelay(): if __name__ == '__main__': - SegWitTest().main() + SegWitTest(__file__).main() diff --git a/test/functional/p2p_sendheaders.py b/test/functional/p2p_sendheaders.py index 5c463267a1c62..db706556d82ff 100755 --- a/test/functional/p2p_sendheaders.py +++ b/test/functional/p2p_sendheaders.py @@ -568,4 +568,4 @@ def test_nonnull_locators(self, test_node, inv_node): assert "getdata" not in inv_node.last_message if __name__ == '__main__': - SendHeadersTest().main() + SendHeadersTest(__file__).main() diff --git a/test/functional/p2p_sendtxrcncl.py b/test/functional/p2p_sendtxrcncl.py index 8f5e6c0387351..2c7216b5ca367 100755 --- a/test/functional/p2p_sendtxrcncl.py +++ b/test/functional/p2p_sendtxrcncl.py @@ -232,4 +232,4 @@ def run_test(self): if __name__ == '__main__': - SendTxRcnclTest().main() + SendTxRcnclTest(__file__).main() diff --git a/test/functional/p2p_timeouts.py b/test/functional/p2p_timeouts.py index 80d7b6e9ae363..1fd78e163b485 100755 --- a/test/functional/p2p_timeouts.py +++ b/test/functional/p2p_timeouts.py @@ -109,4 +109,4 @@ def run_test(self): if __name__ == '__main__': - TimeoutsTest().main() + TimeoutsTest(__file__).main() diff --git a/test/functional/p2p_tx_download.py b/test/functional/p2p_tx_download.py index 0af6b1d2c9734..11b4d9cc3b884 100755 --- a/test/functional/p2p_tx_download.py +++ b/test/functional/p2p_tx_download.py @@ -306,4 +306,4 @@ def run_test(self): if __name__ == '__main__': - TxDownloadTest().main() + TxDownloadTest(__file__).main() diff --git a/test/functional/p2p_tx_privacy.py b/test/functional/p2p_tx_privacy.py index e674f6c3eb63a..afe9df8a0f8e9 100755 --- a/test/functional/p2p_tx_privacy.py +++ b/test/functional/p2p_tx_privacy.py @@ -74,4 +74,4 @@ def run_test(self): spy.wait_for_inv_match(CInv(MSG_WTX, tx2.calc_sha256(True))) if __name__ == '__main__': - TxPrivacyTest().main() + TxPrivacyTest(__file__).main() diff --git a/test/functional/p2p_unrequested_blocks.py b/test/functional/p2p_unrequested_blocks.py index 776eaf5255cfb..835ecbf184f68 100755 --- a/test/functional/p2p_unrequested_blocks.py +++ b/test/functional/p2p_unrequested_blocks.py @@ -296,4 +296,4 @@ def run_test(self): self.log.info("Successfully synced nodes 1 and 0") if __name__ == '__main__': - AcceptBlockTest().main() + AcceptBlockTest(__file__).main() diff --git a/test/functional/p2p_v2_encrypted.py b/test/functional/p2p_v2_encrypted.py index 05755dece05a1..3e8ce09d24d54 100755 --- a/test/functional/p2p_v2_encrypted.py +++ b/test/functional/p2p_v2_encrypted.py @@ -131,4 +131,4 @@ def run_test(self): if __name__ == '__main__': - P2PEncrypted().main() + P2PEncrypted(__file__).main() diff --git a/test/functional/p2p_v2_misbehaving.py b/test/functional/p2p_v2_misbehaving.py index 9017ee94559bf..b66d0289ffc00 100755 --- a/test/functional/p2p_v2_misbehaving.py +++ b/test/functional/p2p_v2_misbehaving.py @@ -185,4 +185,4 @@ def test_v2disconnection(self): if __name__ == '__main__': - EncryptedP2PMisbehaving().main() + EncryptedP2PMisbehaving(__file__).main() diff --git a/test/functional/p2p_v2_transport.py b/test/functional/p2p_v2_transport.py index fe2449124d9f1..94c91906e6fc7 100755 --- a/test/functional/p2p_v2_transport.py +++ b/test/functional/p2p_v2_transport.py @@ -168,4 +168,4 @@ def run_test(self): if __name__ == '__main__': - V2TransportTest().main() + V2TransportTest(__file__).main() diff --git a/test/functional/rpc_bind.py b/test/functional/rpc_bind.py index 3106419e5cd4c..8c76c1f5f59f4 100755 --- a/test/functional/rpc_bind.py +++ b/test/functional/rpc_bind.py @@ -124,4 +124,4 @@ def _run_nonloopback_tests(self): assert_raises_rpc_error(-342, "non-JSON HTTP response with '403 Forbidden' from server", self.run_allowip_test, ['1.1.1.1'], self.non_loopback_ip, self.defaultport) if __name__ == '__main__': - RPCBindTest().main() + RPCBindTest(__file__).main() diff --git a/test/functional/rpc_blockchain.py b/test/functional/rpc_blockchain.py index 9b7743cafa1be..e5aca7f138b04 100755 --- a/test/functional/rpc_blockchain.py +++ b/test/functional/rpc_blockchain.py @@ -635,4 +635,4 @@ def move_block_file(old, new): if __name__ == '__main__': - BlockchainTest().main() + BlockchainTest(__file__).main() diff --git a/test/functional/rpc_createmultisig.py b/test/functional/rpc_createmultisig.py index 37656341d2684..9f4e17a3288e2 100755 --- a/test/functional/rpc_createmultisig.py +++ b/test/functional/rpc_createmultisig.py @@ -257,4 +257,4 @@ def test_sortedmulti_descriptors_bip67(self): if __name__ == '__main__': - RpcCreateMultiSigTest().main() + RpcCreateMultiSigTest(__file__).main() diff --git a/test/functional/rpc_decodescript.py b/test/functional/rpc_decodescript.py index f37e61ab509ea..66dbd785731fc 100755 --- a/test/functional/rpc_decodescript.py +++ b/test/functional/rpc_decodescript.py @@ -289,4 +289,4 @@ def run_test(self): self.decodescript_miniscript() if __name__ == '__main__': - DecodeScriptTest().main() + DecodeScriptTest(__file__).main() diff --git a/test/functional/rpc_deprecated.py b/test/functional/rpc_deprecated.py index 15c77ed856980..4a415d57f55ff 100755 --- a/test/functional/rpc_deprecated.py +++ b/test/functional/rpc_deprecated.py @@ -26,4 +26,4 @@ def run_test(self): self.log.info("No tested deprecated RPC methods") if __name__ == '__main__': - DeprecatedRpcTest().main() + DeprecatedRpcTest(__file__).main() diff --git a/test/functional/rpc_deriveaddresses.py b/test/functional/rpc_deriveaddresses.py index 64994d6bb3086..c66d91713fed9 100755 --- a/test/functional/rpc_deriveaddresses.py +++ b/test/functional/rpc_deriveaddresses.py @@ -61,4 +61,4 @@ def run_test(self): assert_raises_rpc_error(-5, "Descriptor does not have a corresponding address", self.nodes[0].deriveaddresses, bare_multisig_descriptor) if __name__ == '__main__': - DeriveaddressesTest().main() + DeriveaddressesTest(__file__).main() diff --git a/test/functional/rpc_dumptxoutset.py b/test/functional/rpc_dumptxoutset.py index c92c8da357042..0b7c4688465b5 100755 --- a/test/functional/rpc_dumptxoutset.py +++ b/test/functional/rpc_dumptxoutset.py @@ -58,4 +58,4 @@ def run_test(self): if __name__ == '__main__': - DumptxoutsetTest().main() + DumptxoutsetTest(__file__).main() diff --git a/test/functional/rpc_estimatefee.py b/test/functional/rpc_estimatefee.py index 6643799a76700..05ceafbe4e0be 100755 --- a/test/functional/rpc_estimatefee.py +++ b/test/functional/rpc_estimatefee.py @@ -52,4 +52,4 @@ def run_test(self): if __name__ == '__main__': - EstimateFeeTest().main() + EstimateFeeTest(__file__).main() diff --git a/test/functional/rpc_generate.py b/test/functional/rpc_generate.py index 3e250925e78bb..68de9006644b5 100755 --- a/test/functional/rpc_generate.py +++ b/test/functional/rpc_generate.py @@ -126,4 +126,4 @@ def test_generate(self): if __name__ == "__main__": - RPCGenerateTest().main() + RPCGenerateTest(__file__).main() diff --git a/test/functional/rpc_getblockfilter.py b/test/functional/rpc_getblockfilter.py index b09af9e078107..245bcec8e8edb 100755 --- a/test/functional/rpc_getblockfilter.py +++ b/test/functional/rpc_getblockfilter.py @@ -61,4 +61,4 @@ def run_test(self): self.nodes[0].getblockfilter, genesis_hash, filter_type) if __name__ == '__main__': - GetBlockFilterTest().main() + GetBlockFilterTest(__file__).main() diff --git a/test/functional/rpc_getblockfrompeer.py b/test/functional/rpc_getblockfrompeer.py index 1ab1023cf14b3..e309018516c60 100755 --- a/test/functional/rpc_getblockfrompeer.py +++ b/test/functional/rpc_getblockfrompeer.py @@ -154,4 +154,4 @@ def run_test(self): if __name__ == '__main__': - GetBlockFromPeerTest().main() + GetBlockFromPeerTest(__file__).main() diff --git a/test/functional/rpc_getblockstats.py b/test/functional/rpc_getblockstats.py index bf261befcc8e3..d1e4895eb6d51 100755 --- a/test/functional/rpc_getblockstats.py +++ b/test/functional/rpc_getblockstats.py @@ -183,4 +183,4 @@ def run_test(self): assert_equal(tip_stats["utxo_size_inc_actual"], 300) if __name__ == '__main__': - GetblockstatsTest().main() + GetblockstatsTest(__file__).main() diff --git a/test/functional/rpc_getchaintips.py b/test/functional/rpc_getchaintips.py index 7efa306c8c653..1bd4413ce1ec2 100755 --- a/test/functional/rpc_getchaintips.py +++ b/test/functional/rpc_getchaintips.py @@ -58,4 +58,4 @@ def run_test(self): assert_equal (tips[1], shortTip) if __name__ == '__main__': - GetChainTipsTest ().main () + GetChainTipsTest(__file__).main() diff --git a/test/functional/rpc_getdescriptorinfo.py b/test/functional/rpc_getdescriptorinfo.py index 2eb36f260c6db..c84928462dd04 100755 --- a/test/functional/rpc_getdescriptorinfo.py +++ b/test/functional/rpc_getdescriptorinfo.py @@ -63,4 +63,4 @@ def run_test(self): if __name__ == '__main__': - DescriptorTest().main() + DescriptorTest(__file__).main() diff --git a/test/functional/rpc_help.py b/test/functional/rpc_help.py index 53c5aa05e5e8b..4ce24ecb67dd2 100755 --- a/test/functional/rpc_help.py +++ b/test/functional/rpc_help.py @@ -132,4 +132,4 @@ def wallet_help(self): if __name__ == '__main__': - HelpRpcTest().main() + HelpRpcTest(__file__).main() diff --git a/test/functional/rpc_invalid_address_message.py b/test/functional/rpc_invalid_address_message.py index 6759b69dd1bbf..f712530c3bad0 100755 --- a/test/functional/rpc_invalid_address_message.py +++ b/test/functional/rpc_invalid_address_message.py @@ -119,4 +119,4 @@ def run_test(self): if __name__ == '__main__': - InvalidAddressErrorMessageTest().main() + InvalidAddressErrorMessageTest(__file__).main() diff --git a/test/functional/rpc_invalidateblock.py b/test/functional/rpc_invalidateblock.py index 69c5397ce2539..db79d55259007 100755 --- a/test/functional/rpc_invalidateblock.py +++ b/test/functional/rpc_invalidateblock.py @@ -90,4 +90,4 @@ def run_test(self): if __name__ == '__main__': - InvalidateTest().main() + InvalidateTest(__file__).main() diff --git a/test/functional/rpc_mempool_info.py b/test/functional/rpc_mempool_info.py index 246af22e50584..231d93a7b15e5 100755 --- a/test/functional/rpc_mempool_info.py +++ b/test/functional/rpc_mempool_info.py @@ -96,4 +96,4 @@ def create_tx(**kwargs): if __name__ == '__main__': - RPCMempoolInfoTest().main() + RPCMempoolInfoTest(__file__).main() diff --git a/test/functional/rpc_misc.py b/test/functional/rpc_misc.py index 20485c01d35cc..b5c12b28c1ca6 100755 --- a/test/functional/rpc_misc.py +++ b/test/functional/rpc_misc.py @@ -102,4 +102,4 @@ def run_test(self): if __name__ == '__main__': - RpcMiscTest().main() + RpcMiscTest(__file__).main() diff --git a/test/functional/rpc_named_arguments.py b/test/functional/rpc_named_arguments.py index 46d9ffceae129..0385c332671f7 100755 --- a/test/functional/rpc_named_arguments.py +++ b/test/functional/rpc_named_arguments.py @@ -35,4 +35,4 @@ def run_test(self): assert_raises_rpc_error(-8, "Parameter arg1 specified twice both as positional and named argument", node.echo, 0, None, 2, arg1=1) if __name__ == '__main__': - NamedArgumentTest().main() + NamedArgumentTest(__file__).main() diff --git a/test/functional/rpc_net.py b/test/functional/rpc_net.py index 37e2c1fb714d8..b63059b1eecc6 100755 --- a/test/functional/rpc_net.py +++ b/test/functional/rpc_net.py @@ -574,4 +574,4 @@ def check_getrawaddrman_entries(expected): if __name__ == '__main__': - NetTest().main() + NetTest(__file__).main() diff --git a/test/functional/rpc_packages.py b/test/functional/rpc_packages.py index 1acd586d2c419..ef2f66b3a0185 100755 --- a/test/functional/rpc_packages.py +++ b/test/functional/rpc_packages.py @@ -489,4 +489,4 @@ def test_maxburn_submitpackage(self): assert_equal(node.getrawmempool(), [chained_txns_burn[0]["txid"]]) if __name__ == "__main__": - RPCPackagesTest().main() + RPCPackagesTest(__file__).main() diff --git a/test/functional/rpc_preciousblock.py b/test/functional/rpc_preciousblock.py index 3062a86565079..224bba6f9b48a 100755 --- a/test/functional/rpc_preciousblock.py +++ b/test/functional/rpc_preciousblock.py @@ -109,4 +109,4 @@ def run_test(self): assert_equal(self.nodes[2].getbestblockhash(), hashH) if __name__ == '__main__': - PreciousTest().main() + PreciousTest(__file__).main() diff --git a/test/functional/rpc_psbt.py b/test/functional/rpc_psbt.py index a56960adff75e..8c5f98286afff 100755 --- a/test/functional/rpc_psbt.py +++ b/test/functional/rpc_psbt.py @@ -985,4 +985,4 @@ def test_psbt_input_keys(psbt_input, keys): if __name__ == '__main__': - PSBTTest().main() + PSBTTest(__file__).main() diff --git a/test/functional/rpc_rawtransaction.py b/test/functional/rpc_rawtransaction.py index f974a05f7b814..aa179e009d597 100755 --- a/test/functional/rpc_rawtransaction.py +++ b/test/functional/rpc_rawtransaction.py @@ -612,4 +612,4 @@ def raw_multisig_transaction_legacy_tests(self): if __name__ == '__main__': - RawTransactionsTest().main() + RawTransactionsTest(__file__).main() diff --git a/test/functional/rpc_scanblocks.py b/test/functional/rpc_scanblocks.py index 8b4aebc77ac29..d05ba09ba5207 100755 --- a/test/functional/rpc_scanblocks.py +++ b/test/functional/rpc_scanblocks.py @@ -136,4 +136,4 @@ def run_test(self): if __name__ == '__main__': - ScanblocksTest().main() + ScanblocksTest(__file__).main() diff --git a/test/functional/rpc_scantxoutset.py b/test/functional/rpc_scantxoutset.py index 9f77f209efcd4..078a24d577fda 100755 --- a/test/functional/rpc_scantxoutset.py +++ b/test/functional/rpc_scantxoutset.py @@ -131,4 +131,4 @@ def run_test(self): if __name__ == "__main__": - ScantxoutsetTest().main() + ScantxoutsetTest(__file__).main() diff --git a/test/functional/rpc_setban.py b/test/functional/rpc_setban.py index ba86b278bd314..c4e5ebccca2df 100755 --- a/test/functional/rpc_setban.py +++ b/test/functional/rpc_setban.py @@ -75,4 +75,4 @@ def run_test(self): assert_equal(banned['ban_duration'], 1234) if __name__ == '__main__': - SetBanTests().main() + SetBanTests(__file__).main() diff --git a/test/functional/rpc_signer.py b/test/functional/rpc_signer.py index 488682e9591e6..7dd16ea8fee14 100755 --- a/test/functional/rpc_signer.py +++ b/test/functional/rpc_signer.py @@ -77,4 +77,4 @@ def run_test(self): assert_equal({'fingerprint': '00000001', 'name': 'trezor_t'} in self.nodes[1].enumeratesigners()['signers'], True) if __name__ == '__main__': - RPCSignerTest().main() + RPCSignerTest(__file__).main() diff --git a/test/functional/rpc_signmessagewithprivkey.py b/test/functional/rpc_signmessagewithprivkey.py index c5df22157d24f..8e86698781885 100755 --- a/test/functional/rpc_signmessagewithprivkey.py +++ b/test/functional/rpc_signmessagewithprivkey.py @@ -60,4 +60,4 @@ def run_test(self): if __name__ == '__main__': - SignMessagesWithPrivTest().main() + SignMessagesWithPrivTest(__file__).main() diff --git a/test/functional/rpc_signrawtransactionwithkey.py b/test/functional/rpc_signrawtransactionwithkey.py index f4fec13495f78..9dae0ba9942de 100755 --- a/test/functional/rpc_signrawtransactionwithkey.py +++ b/test/functional/rpc_signrawtransactionwithkey.py @@ -143,4 +143,4 @@ def run_test(self): if __name__ == '__main__': - SignRawTransactionWithKeyTest().main() + SignRawTransactionWithKeyTest(__file__).main() diff --git a/test/functional/rpc_txoutproof.py b/test/functional/rpc_txoutproof.py index 60b7ce8d20ecc..387132b68097b 100755 --- a/test/functional/rpc_txoutproof.py +++ b/test/functional/rpc_txoutproof.py @@ -104,4 +104,4 @@ def run_test(self): # verify that the proofs are invalid if __name__ == '__main__': - MerkleBlockTest().main() + MerkleBlockTest(__file__).main() diff --git a/test/functional/rpc_uptime.py b/test/functional/rpc_uptime.py index f8df59d02ad39..fdf459953c006 100755 --- a/test/functional/rpc_uptime.py +++ b/test/functional/rpc_uptime.py @@ -32,4 +32,4 @@ def _test_uptime(self): if __name__ == '__main__': - UptimeTest().main() + UptimeTest(__file__).main() diff --git a/test/functional/rpc_users.py b/test/functional/rpc_users.py index 153493fbabcd1..44187ce7905e0 100755 --- a/test/functional/rpc_users.py +++ b/test/functional/rpc_users.py @@ -156,4 +156,4 @@ def run_test(self): if __name__ == '__main__': - HTTPBasicsTest().main() + HTTPBasicsTest(__file__).main() diff --git a/test/functional/rpc_validateaddress.py b/test/functional/rpc_validateaddress.py index d87ba098c3f88..dde07e7eadd12 100755 --- a/test/functional/rpc_validateaddress.py +++ b/test/functional/rpc_validateaddress.py @@ -200,4 +200,4 @@ def run_test(self): if __name__ == "__main__": - ValidateAddressMainTest().main() + ValidateAddressMainTest(__file__).main() diff --git a/test/functional/rpc_whitelist.py b/test/functional/rpc_whitelist.py index fb404fb479407..5f74fe8274210 100755 --- a/test/functional/rpc_whitelist.py +++ b/test/functional/rpc_whitelist.py @@ -93,4 +93,4 @@ def run_test(self): assert_equal(200, rpccall(self.nodes[0], self.strange_users[4], "getblockcount").status) if __name__ == "__main__": - RPCWhitelistTest().main() + RPCWhitelistTest(__file__).main() diff --git a/test/functional/test_framework/test_framework.py b/test/functional/test_framework/test_framework.py index 9e44a11143fac..3887cc8545a6c 100755 --- a/test/functional/test_framework/test_framework.py +++ b/test/functional/test_framework/test_framework.py @@ -92,7 +92,7 @@ class BitcoinTestFramework(metaclass=BitcoinTestMetaClass): This class also contains various public and private helper methods.""" - def __init__(self) -> None: + def __init__(self, test_file) -> None: """Sets test framework defaults. Do not override this method. Instead, override the set_test_params() method""" self.chain: str = 'regtest' self.setup_clean_chain: bool = False diff --git a/test/functional/tool_signet_miner.py b/test/functional/tool_signet_miner.py index 1ad2a579bfb9e..bdefb92ae6216 100755 --- a/test/functional/tool_signet_miner.py +++ b/test/functional/tool_signet_miner.py @@ -62,4 +62,4 @@ def run_test(self): if __name__ == "__main__": - SignetMinerTest().main() + SignetMinerTest(__file__).main() diff --git a/test/functional/tool_wallet.py b/test/functional/tool_wallet.py index dcf74f6075edb..784a769882918 100755 --- a/test/functional/tool_wallet.py +++ b/test/functional/tool_wallet.py @@ -563,4 +563,4 @@ def run_test(self): self.test_dump_very_large_records() if __name__ == '__main__': - ToolWalletTest().main() + ToolWalletTest(__file__).main() diff --git a/test/functional/wallet_abandonconflict.py b/test/functional/wallet_abandonconflict.py index dda48aae1ba70..ce0f4d099b515 100755 --- a/test/functional/wallet_abandonconflict.py +++ b/test/functional/wallet_abandonconflict.py @@ -241,4 +241,4 @@ def run_test(self): assert_equal(newbalance, balance - Decimal("20")) if __name__ == '__main__': - AbandonConflictTest().main() + AbandonConflictTest(__file__).main() diff --git a/test/functional/wallet_address_types.py b/test/functional/wallet_address_types.py index 6b27b32dea023..e326d3e89e6be 100755 --- a/test/functional/wallet_address_types.py +++ b/test/functional/wallet_address_types.py @@ -387,4 +387,4 @@ def run_test(self): assert_raises_rpc_error(-8, "Legacy wallets cannot provide bech32m addresses", self.nodes[0].getrawchangeaddress, "bech32m") if __name__ == '__main__': - AddressTypeTest().main() + AddressTypeTest(__file__).main() diff --git a/test/functional/wallet_assumeutxo.py b/test/functional/wallet_assumeutxo.py index 30396da01522d..0bce2f137c596 100755 --- a/test/functional/wallet_assumeutxo.py +++ b/test/functional/wallet_assumeutxo.py @@ -164,4 +164,4 @@ def run_test(self): if __name__ == '__main__': - AssumeutxoTest().main() + AssumeutxoTest(__file__).main() diff --git a/test/functional/wallet_avoid_mixing_output_types.py b/test/functional/wallet_avoid_mixing_output_types.py index 66fbf780e5683..146b3df3f4df7 100755 --- a/test/functional/wallet_avoid_mixing_output_types.py +++ b/test/functional/wallet_avoid_mixing_output_types.py @@ -177,4 +177,4 @@ def run_test(self): if __name__ == '__main__': - AddressInputTypeGrouping().main() + AddressInputTypeGrouping(__file__).main() diff --git a/test/functional/wallet_avoidreuse.py b/test/functional/wallet_avoidreuse.py index 4983bfda7f052..bba79d0a258ed 100755 --- a/test/functional/wallet_avoidreuse.py +++ b/test/functional/wallet_avoidreuse.py @@ -381,4 +381,4 @@ def test_all_destination_groups_are_used(self): if __name__ == '__main__': - AvoidReuseTest().main() + AvoidReuseTest(__file__).main() diff --git a/test/functional/wallet_backup.py b/test/functional/wallet_backup.py index d03b08bcc40bb..a639c343772cf 100755 --- a/test/functional/wallet_backup.py +++ b/test/functional/wallet_backup.py @@ -244,4 +244,4 @@ def run_test(self): if __name__ == '__main__': - WalletBackupTest().main() + WalletBackupTest(__file__).main() diff --git a/test/functional/wallet_backwards_compatibility.py b/test/functional/wallet_backwards_compatibility.py index ab008a40cdb90..e71283b9281b0 100755 --- a/test/functional/wallet_backwards_compatibility.py +++ b/test/functional/wallet_backwards_compatibility.py @@ -400,4 +400,4 @@ def run_test(self): assert_equal(info, addr_info) if __name__ == '__main__': - BackwardsCompatibilityTest().main() + BackwardsCompatibilityTest(__file__).main() diff --git a/test/functional/wallet_balance.py b/test/functional/wallet_balance.py index 2c85773bf3a57..9da53402a45df 100755 --- a/test/functional/wallet_balance.py +++ b/test/functional/wallet_balance.py @@ -339,4 +339,4 @@ def test_balances(*, fee_node_1=0): assert_equal(tx_info['lastprocessedblock']['hash'], prev_hash) if __name__ == '__main__': - WalletTest().main() + WalletTest(__file__).main() diff --git a/test/functional/wallet_basic.py b/test/functional/wallet_basic.py index 1b2b8ec1f3c8b..c968e4333a0ea 100755 --- a/test/functional/wallet_basic.py +++ b/test/functional/wallet_basic.py @@ -818,4 +818,4 @@ def test_chain_listunspent(self): if __name__ == '__main__': - WalletTest().main() + WalletTest(__file__).main() diff --git a/test/functional/wallet_blank.py b/test/functional/wallet_blank.py index e646d270059df..76f9cb05ee6dc 100755 --- a/test/functional/wallet_blank.py +++ b/test/functional/wallet_blank.py @@ -160,4 +160,4 @@ def run_test(self): if __name__ == '__main__': - WalletBlankTest().main() + WalletBlankTest(__file__).main() diff --git a/test/functional/wallet_bumpfee.py b/test/functional/wallet_bumpfee.py index 6d45adc823d47..81c1c8c1b3477 100755 --- a/test/functional/wallet_bumpfee.py +++ b/test/functional/wallet_bumpfee.py @@ -854,4 +854,4 @@ def test_bumpfee_with_feerate_ignores_walletincrementalrelayfee(self, rbf_node, if __name__ == "__main__": - BumpFeeTest().main() + BumpFeeTest(__file__).main() diff --git a/test/functional/wallet_change_address.py b/test/functional/wallet_change_address.py index f8bfe9eebf12a..07bab82697ecb 100755 --- a/test/functional/wallet_change_address.py +++ b/test/functional/wallet_change_address.py @@ -105,4 +105,4 @@ def run_test(self): self.assert_change_pos(w1, tx, 0) if __name__ == '__main__': - WalletChangeAddressTest().main() + WalletChangeAddressTest(__file__).main() diff --git a/test/functional/wallet_coinbase_category.py b/test/functional/wallet_coinbase_category.py index c2cb0bf3b07d6..f09ed4913a259 100755 --- a/test/functional/wallet_coinbase_category.py +++ b/test/functional/wallet_coinbase_category.py @@ -60,4 +60,4 @@ def run_test(self): self.assert_category("orphan", address, txid, 100) if __name__ == '__main__': - CoinbaseCategoryTest().main() + CoinbaseCategoryTest(__file__).main() diff --git a/test/functional/wallet_conflicts.py b/test/functional/wallet_conflicts.py index 25a95aa954d2a..7a950ffae6f10 100755 --- a/test/functional/wallet_conflicts.py +++ b/test/functional/wallet_conflicts.py @@ -423,4 +423,4 @@ def test_descendants_with_mempool_conflicts(self): carol.unloadwallet() if __name__ == '__main__': - TxConflicts().main() + TxConflicts(__file__).main() diff --git a/test/functional/wallet_create_tx.py b/test/functional/wallet_create_tx.py index 41ddb2bc69ee7..6deb262c9aab8 100755 --- a/test/functional/wallet_create_tx.py +++ b/test/functional/wallet_create_tx.py @@ -129,4 +129,4 @@ def test_version3(self): if __name__ == '__main__': - CreateTxWalletTest().main() + CreateTxWalletTest(__file__).main() diff --git a/test/functional/wallet_createwallet.py b/test/functional/wallet_createwallet.py index 8e07021e03685..0232af1658fa8 100755 --- a/test/functional/wallet_createwallet.py +++ b/test/functional/wallet_createwallet.py @@ -190,4 +190,4 @@ def run_test(self): if __name__ == '__main__': - CreateWalletTest().main() + CreateWalletTest(__file__).main() diff --git a/test/functional/wallet_createwalletdescriptor.py b/test/functional/wallet_createwalletdescriptor.py index 18e1703da37b6..e8cd914769d0b 100755 --- a/test/functional/wallet_createwalletdescriptor.py +++ b/test/functional/wallet_createwalletdescriptor.py @@ -120,4 +120,4 @@ def test_encrypted(self): if __name__ == '__main__': - WalletCreateDescriptorTest().main() + WalletCreateDescriptorTest(__file__).main() diff --git a/test/functional/wallet_crosschain.py b/test/functional/wallet_crosschain.py index 4c5d7192ae076..3505d33e513f4 100755 --- a/test/functional/wallet_crosschain.py +++ b/test/functional/wallet_crosschain.py @@ -62,4 +62,4 @@ def run_test(self): if __name__ == '__main__': - WalletCrossChain().main() + WalletCrossChain(__file__).main() diff --git a/test/functional/wallet_descriptor.py b/test/functional/wallet_descriptor.py index cbd3898f92b00..5e0ee97892172 100755 --- a/test/functional/wallet_descriptor.py +++ b/test/functional/wallet_descriptor.py @@ -282,4 +282,4 @@ def run_test(self): if __name__ == '__main__': - WalletDescriptorTest().main () + WalletDescriptorTest(__file__).main() diff --git a/test/functional/wallet_disable.py b/test/functional/wallet_disable.py index 9c73f7dead6a1..da6e5d408f38d 100755 --- a/test/functional/wallet_disable.py +++ b/test/functional/wallet_disable.py @@ -28,4 +28,4 @@ def run_test (self): if __name__ == '__main__': - DisableWalletTest().main() + DisableWalletTest(__file__).main() diff --git a/test/functional/wallet_dump.py b/test/functional/wallet_dump.py index f50aae0c53530..3a4f23a124538 100755 --- a/test/functional/wallet_dump.py +++ b/test/functional/wallet_dump.py @@ -223,4 +223,4 @@ def run_test(self): w3.dumpwallet(self.nodes[0].datadir_path / "w3.dump") if __name__ == '__main__': - WalletDumpTest().main() + WalletDumpTest(__file__).main() diff --git a/test/functional/wallet_encryption.py b/test/functional/wallet_encryption.py index b30634010d5a1..5a5fb3e5be377 100755 --- a/test/functional/wallet_encryption.py +++ b/test/functional/wallet_encryption.py @@ -102,4 +102,4 @@ def run_test(self): if __name__ == '__main__': - WalletEncryptionTest().main() + WalletEncryptionTest(__file__).main() diff --git a/test/functional/wallet_fallbackfee.py b/test/functional/wallet_fallbackfee.py index f0740b72fdd48..1849a602abd39 100755 --- a/test/functional/wallet_fallbackfee.py +++ b/test/functional/wallet_fallbackfee.py @@ -32,4 +32,4 @@ def run_test(self): assert_raises_rpc_error(-6, "Fee estimation failed", lambda: self.nodes[0].sendmany("", {self.nodes[0].getnewaddress(): 1})) if __name__ == '__main__': - WalletRBFTest().main() + WalletRBFTest(__file__).main() diff --git a/test/functional/wallet_fast_rescan.py b/test/functional/wallet_fast_rescan.py index 1315bccafdcce..4ac441516e5f6 100755 --- a/test/functional/wallet_fast_rescan.py +++ b/test/functional/wallet_fast_rescan.py @@ -99,4 +99,4 @@ def run_test(self): if __name__ == '__main__': - WalletFastRescanTest().main() + WalletFastRescanTest(__file__).main() diff --git a/test/functional/wallet_fundrawtransaction.py b/test/functional/wallet_fundrawtransaction.py index 07737c273d025..827f27b431c7d 100755 --- a/test/functional/wallet_fundrawtransaction.py +++ b/test/functional/wallet_fundrawtransaction.py @@ -1523,4 +1523,4 @@ def test_input_confs_control(self): wallet.unloadwallet() if __name__ == '__main__': - RawTransactionsTest().main() + RawTransactionsTest(__file__).main() diff --git a/test/functional/wallet_gethdkeys.py b/test/functional/wallet_gethdkeys.py index f09b8c875a50d..b6edc29fe61ab 100755 --- a/test/functional/wallet_gethdkeys.py +++ b/test/functional/wallet_gethdkeys.py @@ -182,4 +182,4 @@ def test_mixed_multisig(self): if __name__ == '__main__': - WalletGetHDKeyTest().main() + WalletGetHDKeyTest(__file__).main() diff --git a/test/functional/wallet_groups.py b/test/functional/wallet_groups.py index 26477131cf2fe..8d6c96c0e004c 100755 --- a/test/functional/wallet_groups.py +++ b/test/functional/wallet_groups.py @@ -182,4 +182,4 @@ def run_test(self): if __name__ == '__main__': - WalletGroupTest().main() + WalletGroupTest(__file__).main() diff --git a/test/functional/wallet_hd.py b/test/functional/wallet_hd.py index 52161043eacaf..8f2a5fc78b419 100755 --- a/test/functional/wallet_hd.py +++ b/test/functional/wallet_hd.py @@ -280,4 +280,4 @@ def run_test(self): if __name__ == '__main__': - WalletHDTest().main() + WalletHDTest(__file__).main() diff --git a/test/functional/wallet_implicitsegwit.py b/test/functional/wallet_implicitsegwit.py index baa9bafb00d99..e5787c0304971 100755 --- a/test/functional/wallet_implicitsegwit.py +++ b/test/functional/wallet_implicitsegwit.py @@ -65,4 +65,4 @@ def run_test(self): check_implicit_transactions(implicit_keys, self.nodes[0]) if __name__ == '__main__': - ImplicitSegwitTest().main() + ImplicitSegwitTest(__file__).main() diff --git a/test/functional/wallet_import_rescan.py b/test/functional/wallet_import_rescan.py index 2a9435b37060f..c5834c15d200b 100755 --- a/test/functional/wallet_import_rescan.py +++ b/test/functional/wallet_import_rescan.py @@ -338,4 +338,4 @@ def run_test(self): if __name__ == "__main__": - ImportRescanTest().main() + ImportRescanTest(__file__).main() diff --git a/test/functional/wallet_import_with_label.py b/test/functional/wallet_import_with_label.py index 0a1fc31ebc570..9d01dfa5b760d 100755 --- a/test/functional/wallet_import_with_label.py +++ b/test/functional/wallet_import_with_label.py @@ -125,4 +125,4 @@ def run_test(self): if __name__ == "__main__": - ImportWithLabel().main() + ImportWithLabel(__file__).main() diff --git a/test/functional/wallet_importdescriptors.py b/test/functional/wallet_importdescriptors.py index f9d05a2fe40e7..6a69377c63425 100755 --- a/test/functional/wallet_importdescriptors.py +++ b/test/functional/wallet_importdescriptors.py @@ -709,4 +709,4 @@ def run_test(self): assert_equal(temp_wallet.getbalance(), encrypted_wallet.getbalance()) if __name__ == '__main__': - ImportDescriptorsTest().main() + ImportDescriptorsTest(__file__).main() diff --git a/test/functional/wallet_importmulti.py b/test/functional/wallet_importmulti.py index 31013f6323f9f..42b470bb97617 100755 --- a/test/functional/wallet_importmulti.py +++ b/test/functional/wallet_importmulti.py @@ -898,4 +898,4 @@ def run_test(self): if __name__ == '__main__': - ImportMultiTest().main() + ImportMultiTest(__file__).main() diff --git a/test/functional/wallet_importprunedfunds.py b/test/functional/wallet_importprunedfunds.py index b3ae22cc445c7..467fddeb59087 100755 --- a/test/functional/wallet_importprunedfunds.py +++ b/test/functional/wallet_importprunedfunds.py @@ -143,4 +143,4 @@ def run_test(self): if __name__ == '__main__': - ImportPrunedFundsTest().main() + ImportPrunedFundsTest(__file__).main() diff --git a/test/functional/wallet_inactive_hdchains.py b/test/functional/wallet_inactive_hdchains.py index c6d22ab90b472..3b0c09c02bed0 100755 --- a/test/functional/wallet_inactive_hdchains.py +++ b/test/functional/wallet_inactive_hdchains.py @@ -146,4 +146,4 @@ def run_test(self): if __name__ == '__main__': - InactiveHDChainsTest().main() + InactiveHDChainsTest(__file__).main() diff --git a/test/functional/wallet_keypool.py b/test/functional/wallet_keypool.py index 6ed8572347dad..d3b6ca1ed1112 100755 --- a/test/functional/wallet_keypool.py +++ b/test/functional/wallet_keypool.py @@ -223,4 +223,4 @@ def run_test(self): assert_raises_rpc_error(-4, msg, w2.keypoolrefill, 100) if __name__ == '__main__': - KeyPoolTest().main() + KeyPoolTest(__file__).main() diff --git a/test/functional/wallet_keypool_topup.py b/test/functional/wallet_keypool_topup.py index e1bd85d8a9963..25028d87bfa29 100755 --- a/test/functional/wallet_keypool_topup.py +++ b/test/functional/wallet_keypool_topup.py @@ -98,4 +98,4 @@ def run_test(self): if __name__ == '__main__': - KeypoolRestoreTest().main() + KeypoolRestoreTest(__file__).main() diff --git a/test/functional/wallet_labels.py b/test/functional/wallet_labels.py index f074339a2bdd9..307e10ae34d13 100755 --- a/test/functional/wallet_labels.py +++ b/test/functional/wallet_labels.py @@ -256,4 +256,4 @@ def change_label(node, address, old_label, new_label): new_label.verify(node) if __name__ == '__main__': - WalletLabelsTest().main() + WalletLabelsTest(__file__).main() diff --git a/test/functional/wallet_listdescriptors.py b/test/functional/wallet_listdescriptors.py index 712b881322d7d..c9d6c1f190df5 100755 --- a/test/functional/wallet_listdescriptors.py +++ b/test/functional/wallet_listdescriptors.py @@ -136,4 +136,4 @@ def run_test(self): if __name__ == '__main__': - ListDescriptorsTest().main() + ListDescriptorsTest(__file__).main() diff --git a/test/functional/wallet_listreceivedby.py b/test/functional/wallet_listreceivedby.py index d0f1336a5ebca..522c7732fef40 100755 --- a/test/functional/wallet_listreceivedby.py +++ b/test/functional/wallet_listreceivedby.py @@ -263,4 +263,4 @@ def run_test(self): if __name__ == '__main__': - ReceivedByTest().main() + ReceivedByTest(__file__).main() diff --git a/test/functional/wallet_listsinceblock.py b/test/functional/wallet_listsinceblock.py index 15214539a973c..d777212f96cfd 100755 --- a/test/functional/wallet_listsinceblock.py +++ b/test/functional/wallet_listsinceblock.py @@ -505,4 +505,4 @@ def test_label(self): if __name__ == '__main__': - ListSinceBlockTest().main() + ListSinceBlockTest(__file__).main() diff --git a/test/functional/wallet_listtransactions.py b/test/functional/wallet_listtransactions.py index c820eaa6f6090..a9f2066dd19b6 100755 --- a/test/functional/wallet_listtransactions.py +++ b/test/functional/wallet_listtransactions.py @@ -330,4 +330,4 @@ def test_op_return(self): if __name__ == '__main__': - ListTransactionsTest().main() + ListTransactionsTest(__file__).main() diff --git a/test/functional/wallet_migration.py b/test/functional/wallet_migration.py index 8fdc284d241d6..b4dc163e341f6 100755 --- a/test/functional/wallet_migration.py +++ b/test/functional/wallet_migration.py @@ -1032,4 +1032,4 @@ def run_test(self): self.test_blank() if __name__ == '__main__': - WalletMigrationTest().main() + WalletMigrationTest(__file__).main() diff --git a/test/functional/wallet_miniscript.py b/test/functional/wallet_miniscript.py index 67e128390200c..064eac499b2fe 100755 --- a/test/functional/wallet_miniscript.py +++ b/test/functional/wallet_miniscript.py @@ -401,4 +401,4 @@ def run_test(self): if __name__ == "__main__": - WalletMiniscriptTest().main() + WalletMiniscriptTest(__file__).main() diff --git a/test/functional/wallet_multisig_descriptor_psbt.py b/test/functional/wallet_multisig_descriptor_psbt.py index 145912025f0a6..2e0b0d1a41b1a 100755 --- a/test/functional/wallet_multisig_descriptor_psbt.py +++ b/test/functional/wallet_multisig_descriptor_psbt.py @@ -154,4 +154,4 @@ def run_test(self): if __name__ == "__main__": - WalletMultisigDescriptorPSBTTest().main() + WalletMultisigDescriptorPSBTTest(__file__).main() diff --git a/test/functional/wallet_multiwallet.py b/test/functional/wallet_multiwallet.py index ee866ee59ba59..156f4279b4381 100755 --- a/test/functional/wallet_multiwallet.py +++ b/test/functional/wallet_multiwallet.py @@ -423,4 +423,4 @@ def wallet_file(name): if __name__ == '__main__': - MultiWalletTest().main() + MultiWalletTest(__file__).main() diff --git a/test/functional/wallet_orphanedreward.py b/test/functional/wallet_orphanedreward.py index 451f8abb0a535..8a02781f26cff 100755 --- a/test/functional/wallet_orphanedreward.py +++ b/test/functional/wallet_orphanedreward.py @@ -73,4 +73,4 @@ def run_test(self): if __name__ == '__main__': - OrphanedBlockRewardTest().main() + OrphanedBlockRewardTest(__file__).main() diff --git a/test/functional/wallet_pruning.py b/test/functional/wallet_pruning.py index 6e252b5406289..9c34a24be95d1 100755 --- a/test/functional/wallet_pruning.py +++ b/test/functional/wallet_pruning.py @@ -155,4 +155,4 @@ def run_test(self): self.test_wallet_import_pruned_with_missing_blocks(wallet_birthheight_1) if __name__ == '__main__': - WalletPruningTest().main() + WalletPruningTest(__file__).main() diff --git a/test/functional/wallet_reindex.py b/test/functional/wallet_reindex.py index 5388de4b7171f..6778f76efc071 100755 --- a/test/functional/wallet_reindex.py +++ b/test/functional/wallet_reindex.py @@ -105,4 +105,4 @@ def run_test(self): if __name__ == '__main__': - WalletReindexTest().main() + WalletReindexTest(__file__).main() diff --git a/test/functional/wallet_reorgsrestore.py b/test/functional/wallet_reorgsrestore.py index 4271f3e481e32..77cf34898bd81 100755 --- a/test/functional/wallet_reorgsrestore.py +++ b/test/functional/wallet_reorgsrestore.py @@ -101,4 +101,4 @@ def run_test(self): assert conflicting["blockhash"] != conflicted_after_reorg["blockhash"] if __name__ == '__main__': - ReorgsRestoreTest().main() + ReorgsRestoreTest(__file__).main() diff --git a/test/functional/wallet_rescan_unconfirmed.py b/test/functional/wallet_rescan_unconfirmed.py index ad9fa081c21e6..69ad522b5d3ce 100755 --- a/test/functional/wallet_rescan_unconfirmed.py +++ b/test/functional/wallet_rescan_unconfirmed.py @@ -80,4 +80,4 @@ def run_test(self): assert_equal(w1.gettransaction(tx_child_unconfirmed_sweep["txid"])["confirmations"], 0) if __name__ == '__main__': - WalletRescanUnconfirmed().main() + WalletRescanUnconfirmed(__file__).main() diff --git a/test/functional/wallet_resendwallettransactions.py b/test/functional/wallet_resendwallettransactions.py index f61e1edc1def7..49c8ef1c5fe45 100755 --- a/test/functional/wallet_resendwallettransactions.py +++ b/test/functional/wallet_resendwallettransactions.py @@ -149,4 +149,4 @@ def run_test(self): if __name__ == '__main__': - ResendWalletTransactionsTest().main() + ResendWalletTransactionsTest(__file__).main() diff --git a/test/functional/wallet_send.py b/test/functional/wallet_send.py index bbb0d658d961c..2d0aad3b5d69d 100755 --- a/test/functional/wallet_send.py +++ b/test/functional/wallet_send.py @@ -612,4 +612,4 @@ def test_weight_limits(self): if __name__ == '__main__': - WalletSendTest().main() + WalletSendTest(__file__).main() diff --git a/test/functional/wallet_sendall.py b/test/functional/wallet_sendall.py index 1d308c225d90b..b256b53b38a8b 100755 --- a/test/functional/wallet_sendall.py +++ b/test/functional/wallet_sendall.py @@ -531,4 +531,4 @@ def run_test(self): self.sendall_fails_with_transaction_too_large() if __name__ == '__main__': - SendallTest().main() + SendallTest(__file__).main() diff --git a/test/functional/wallet_sendmany.py b/test/functional/wallet_sendmany.py index 5751993143341..ad99100590b3f 100755 --- a/test/functional/wallet_sendmany.py +++ b/test/functional/wallet_sendmany.py @@ -40,4 +40,4 @@ def run_test(self): if __name__ == '__main__': - SendmanyTest().main() + SendmanyTest(__file__).main() diff --git a/test/functional/wallet_signer.py b/test/functional/wallet_signer.py index abfc3c1ba1b89..52b4c390b83fb 100755 --- a/test/functional/wallet_signer.py +++ b/test/functional/wallet_signer.py @@ -263,4 +263,4 @@ def test_multiple_signers(self): assert_raises_rpc_error(-1, "GetExternalSigner: More than one external signer found", self.nodes[1].createwallet, wallet_name='multi_hww', disable_private_keys=True, descriptors=True, external_signer=True) if __name__ == '__main__': - WalletSignerTest().main() + WalletSignerTest(__file__).main() diff --git a/test/functional/wallet_signmessagewithaddress.py b/test/functional/wallet_signmessagewithaddress.py index 4a4b818bd1ab0..170c883ca4053 100755 --- a/test/functional/wallet_signmessagewithaddress.py +++ b/test/functional/wallet_signmessagewithaddress.py @@ -45,4 +45,4 @@ def run_test(self): if __name__ == '__main__': - SignMessagesWithAddressTest().main() + SignMessagesWithAddressTest(__file__).main() diff --git a/test/functional/wallet_signrawtransactionwithwallet.py b/test/functional/wallet_signrawtransactionwithwallet.py index 612a2542e7425..eb0e4097fed19 100755 --- a/test/functional/wallet_signrawtransactionwithwallet.py +++ b/test/functional/wallet_signrawtransactionwithwallet.py @@ -310,4 +310,4 @@ def run_test(self): if __name__ == '__main__': - SignRawTransactionWithWalletTest().main() + SignRawTransactionWithWalletTest(__file__).main() diff --git a/test/functional/wallet_simulaterawtx.py b/test/functional/wallet_simulaterawtx.py index 545aad892cb72..11b7a4c76e2b5 100755 --- a/test/functional/wallet_simulaterawtx.py +++ b/test/functional/wallet_simulaterawtx.py @@ -129,4 +129,4 @@ def run_test(self): assert_raises_rpc_error(-8, "One or more transaction inputs are missing or have been spent already", w2.simulaterawtransaction, [tx1, tx2]) if __name__ == '__main__': - SimulateTxTest().main() + SimulateTxTest(__file__).main() diff --git a/test/functional/wallet_spend_unconfirmed.py b/test/functional/wallet_spend_unconfirmed.py index bfcdeaeaa8995..4c73e0970b48a 100755 --- a/test/functional/wallet_spend_unconfirmed.py +++ b/test/functional/wallet_spend_unconfirmed.py @@ -505,4 +505,4 @@ def run_test(self): self.test_external_input_unconfirmed_low() if __name__ == '__main__': - UnconfirmedInputTest().main() + UnconfirmedInputTest(__file__).main() diff --git a/test/functional/wallet_startup.py b/test/functional/wallet_startup.py index 2cc4e312afa8c..6feb00af8e1dd 100755 --- a/test/functional/wallet_startup.py +++ b/test/functional/wallet_startup.py @@ -58,4 +58,4 @@ def run_test(self): assert_equal(set(self.nodes[0].listwallets()), set(('w2', 'w3'))) if __name__ == '__main__': - WalletStartupTest().main() + WalletStartupTest(__file__).main() diff --git a/test/functional/wallet_taproot.py b/test/functional/wallet_taproot.py index a5d7445ce8d84..a88d84f4c6b2b 100755 --- a/test/functional/wallet_taproot.py +++ b/test/functional/wallet_taproot.py @@ -507,4 +507,4 @@ def run_test(self): ) if __name__ == '__main__': - WalletTaprootTest().main() + WalletTaprootTest(__file__).main() diff --git a/test/functional/wallet_timelock.py b/test/functional/wallet_timelock.py index 0a622979a49c1..6c88438330a9c 100755 --- a/test/functional/wallet_timelock.py +++ b/test/functional/wallet_timelock.py @@ -50,4 +50,4 @@ def run_test(self): if __name__ == "__main__": - WalletLocktimeTest().main() + WalletLocktimeTest(__file__).main() diff --git a/test/functional/wallet_transactiontime_rescan.py b/test/functional/wallet_transactiontime_rescan.py index ea99992084865..fb6dc74dc5396 100755 --- a/test/functional/wallet_transactiontime_rescan.py +++ b/test/functional/wallet_transactiontime_rescan.py @@ -223,4 +223,4 @@ def run_test(self): assert_equal(encrypted_wallet.getbalance(), temp_wallet.getbalance()) if __name__ == '__main__': - TransactionTimeRescanTest().main() + TransactionTimeRescanTest(__file__).main() diff --git a/test/functional/wallet_txn_clone.py b/test/functional/wallet_txn_clone.py index 1f3b6f2ce925e..a2dd223aed662 100755 --- a/test/functional/wallet_txn_clone.py +++ b/test/functional/wallet_txn_clone.py @@ -149,4 +149,4 @@ def run_test(self): if __name__ == '__main__': - TxnMallTest().main() + TxnMallTest(__file__).main() diff --git a/test/functional/wallet_txn_doublespend.py b/test/functional/wallet_txn_doublespend.py index 3cd0cd3207d41..3d6830f1f35df 100755 --- a/test/functional/wallet_txn_doublespend.py +++ b/test/functional/wallet_txn_doublespend.py @@ -138,4 +138,4 @@ def run_test(self): if __name__ == '__main__': - TxnMallTest().main() + TxnMallTest(__file__).main() diff --git a/test/functional/wallet_upgradewallet.py b/test/functional/wallet_upgradewallet.py index a4f2a9b74dd5b..7d1d244dffd91 100755 --- a/test/functional/wallet_upgradewallet.py +++ b/test/functional/wallet_upgradewallet.py @@ -360,4 +360,4 @@ def copy_split_hd(): self.test_upgradewallet(disabled_wallet, previous_version=169900, expected_version=169900) if __name__ == '__main__': - UpgradeWalletTest().main() + UpgradeWalletTest(__file__).main() diff --git a/test/functional/wallet_watchonly.py b/test/functional/wallet_watchonly.py index b473f5d65c1c0..298d50d45248c 100755 --- a/test/functional/wallet_watchonly.py +++ b/test/functional/wallet_watchonly.py @@ -111,4 +111,4 @@ def run_test(self): if __name__ == '__main__': - CreateWalletWatchonlyTest().main() + CreateWalletWatchonlyTest(__file__).main() From 9bf7ca6cad888d460f57d249264dc0062025bb3f Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Sat, 13 Jul 2024 12:31:19 +0100 Subject: [PATCH 2/3] qa: Consider `cache` and `config.ini` relative to invocation directory In CMake-based build system (1) `config.ini` is created in the build directory, and (2) `cache` must also be created in the same directory. This change enables running individual functional tests from the build directory. --- test/functional/test_framework/test_framework.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/functional/test_framework/test_framework.py b/test/functional/test_framework/test_framework.py index 3887cc8545a6c..49212eb0195d7 100755 --- a/test/functional/test_framework/test_framework.py +++ b/test/functional/test_framework/test_framework.py @@ -103,7 +103,7 @@ def __init__(self, test_file) -> None: self.rpc_timeout = 60 # Wait for up to 60 seconds for the RPC server to respond self.supports_cli = True self.bind_to_localhost_only = True - self.parse_args() + self.parse_args(test_file) self.default_wallet_name = "default_wallet" if self.options.descriptors else "" self.wallet_data_filename = "wallet.dat" # Optional list of wallet names that can be set in set_test_params to @@ -155,14 +155,14 @@ def main(self): exit_code = self.shutdown() sys.exit(exit_code) - def parse_args(self): + def parse_args(self, test_file): previous_releases_path = os.getenv("PREVIOUS_RELEASES_DIR") or os.getcwd() + "/releases" parser = argparse.ArgumentParser(usage="%(prog)s [options]") parser.add_argument("--nocleanup", dest="nocleanup", default=False, action="store_true", help="Leave bitcoinds and test.* datadir on exit or error") parser.add_argument("--noshutdown", dest="noshutdown", default=False, action="store_true", help="Don't stop bitcoinds after the test execution") - parser.add_argument("--cachedir", dest="cachedir", default=os.path.abspath(os.path.dirname(os.path.realpath(__file__)) + "/../../cache"), + parser.add_argument("--cachedir", dest="cachedir", default=os.path.abspath(os.path.dirname(test_file) + "/../cache"), help="Directory for caching pregenerated datadirs (default: %(default)s)") parser.add_argument("--tmpdir", dest="tmpdir", help="Root directory for datadirs (must not exist)") parser.add_argument("-l", "--loglevel", dest="loglevel", default="INFO", @@ -177,7 +177,7 @@ def parse_args(self): parser.add_argument("--coveragedir", dest="coveragedir", help="Write tested RPC commands into this directory") parser.add_argument("--configfile", dest="configfile", - default=os.path.abspath(os.path.dirname(os.path.realpath(__file__)) + "/../../config.ini"), + default=os.path.abspath(os.path.dirname(test_file) + "/../config.ini"), help="Location of the test framework config file (default: %(default)s)") parser.add_argument("--pdbonfailure", dest="pdbonfailure", default=False, action="store_true", help="Attach a python debugger if test fails") From a8e3af1a82dd584a1cc3ffbe587e66889f72e3c7 Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Sat, 8 Jun 2024 23:58:40 +0100 Subject: [PATCH 3/3] qa: Do not assume running `feature_asmap.py` from source directory --- test/functional/feature_asmap.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/functional/feature_asmap.py b/test/functional/feature_asmap.py index cbff028bcc358..53e94bf4dfbe4 100755 --- a/test/functional/feature_asmap.py +++ b/test/functional/feature_asmap.py @@ -30,7 +30,7 @@ from test_framework.util import assert_equal DEFAULT_ASMAP_FILENAME = 'ip_asn.map' # defined in src/init.cpp -ASMAP = '../../src/test/data/asmap.raw' # path to unit test skeleton asmap +ASMAP = 'src/test/data/asmap.raw' # path to unit test skeleton asmap VERSION = 'fec61fa21a9f46f3b17bdcd660d7f4cd90b966aad3aec593c99b35f0aca15853' def expected_messages(filename): @@ -133,7 +133,8 @@ def run_test(self): self.node = self.nodes[0] self.datadir = self.node.chain_path self.default_asmap = os.path.join(self.datadir, DEFAULT_ASMAP_FILENAME) - self.asmap_raw = os.path.join(os.path.dirname(os.path.realpath(__file__)), ASMAP) + base_dir = self.config["environment"]["SRCDIR"] + self.asmap_raw = os.path.join(base_dir, ASMAP) self.test_without_asmap_arg() self.test_asmap_with_absolute_path()