Skip to content

Commit 3cceb60

Browse files
ryanofskysipa
authored andcommitted
test: Provide path to bitcoin binary
Set new `BitcoinTestFramework.binary_paths.bitcoin_bin` property with path to the `bitcoin` wrapper binary. This allows new tests for `bitcoin-mine` in #30437 and `bitcoin-cli` in #32297 to find the `bitcoin` binary and call `bitcoin -m` to start nodes with IPC support. This way the new tests can run whenever the ENABLE_IPC build option is enabled, instead of only running when the `BITCOIN_CMD` environment variable is set to `bitcoin -m`
1 parent 8c7f005 commit 3cceb60

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,7 @@ jobs:
275275
if: matrix.job-type == 'standard'
276276
working-directory: build
277277
env:
278+
BITCOIN_BIN: '${{ github.workspace }}\build\bin\Release\bitcoin.exe'
278279
BITCOIND: '${{ github.workspace }}\build\bin\Release\bitcoind.exe'
279280
BITCOINCLI: '${{ github.workspace }}\build\bin\Release\bitcoin-cli.exe'
280281
BITCOINTX: '${{ github.workspace }}\build\bin\Release\bitcoin-tx.exe'

test/functional/test_framework/test_framework.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,13 +278,16 @@ def get_binary_paths(self):
278278

279279
paths = types.SimpleNamespace()
280280
binaries = {
281+
"bitcoin": "BITCOIN_BIN",
281282
"bitcoind": "BITCOIND",
282283
"bitcoin-cli": "BITCOINCLI",
283284
"bitcoin-util": "BITCOINUTIL",
284285
"bitcoin-tx": "BITCOINTX",
285286
"bitcoin-chainstate": "BITCOINCHAINSTATE",
286287
"bitcoin-wallet": "BITCOINWALLET",
287288
}
289+
# Set paths to bitcoin core binaries allowing overrides with environment
290+
# variables.
288291
for binary, env_variable_name in binaries.items():
289292
default_filename = os.path.join(
290293
self.config["environment"]["BUILDDIR"],

0 commit comments

Comments
 (0)