-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
Signed-off-by: Vu Vo <[email protected]>
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -64,6 +64,22 @@ bitcoin-cli -regtest -rpcuser=user -rpcpassword=password -generate <number-block | |
|
||
More information in [developer.bitcoin.org -> testing](https://developer.bitcoin.org/examples/testing.html). | ||
|
||
### Create BTC fork for testing | ||
Check failure on line 67 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintTrailing spaces
|
||
|
||
In a few cases, we must create a BTC fork for testing. The create-fork.sh script helps you to do this. We support two functions: | ||
Check failure on line 69 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintTrailing spaces
|
||
|
||
#### Create fork | ||
Check failure on line 71 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintHeadings should be surrounded by blank lines
|
||
Create a new fork start at the latest block in the snapshot data. | ||
Check failure on line 72 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintTrailing spaces
|
||
```sh | ||
Check failure on line 73 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintFenced code blocks should be surrounded by blank lines
|
||
./create-fork.sh create <fork-name> <number-block> | ||
``` | ||
Check failure on line 75 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintFenced code blocks should be surrounded by blank lines
|
||
### Extract fork | ||
Check failure on line 76 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintTrailing spaces
Check failure on line 76 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintHeadings should be surrounded by blank lines
Check failure on line 76 in contrib/bitcoin-mock.md GitHub Actions / markdown-lintHeadings should be surrounded by blank lines
|
||
We can extract any block between a specific range. This command below returns the list of block headers in this range. | ||
|
||
```sh | ||
./create-fork.sh extract <fork-name> <start> <end> | ||
``` | ||
|
||
### Reference | ||
|
||
- [Running Bitcoind with ZMQ](https://bitcoindev.network/accessing-bitcoins-zeromq-interface/) | ||
|