Skip to content

Commit 80e190b

Browse files
committed
Merge #1171: chore: extract TestEnv into separate crate
7c9ba3c chore(electrum,testenv): move `test_reorg_is_detected_in_electrsd` (志宇) 2462e90 chore(esplora): rm custom WASM target spec test dependency (志宇) 04d0ab5 test(electrum): added scan and reorg tests Added scan and reorg tests to check electrum functionality using `TestEnv`. (Wei Chen) 4edf533 chore: extract `TestEnv` into separate crate `TestEnv` is extracted into its own crate to serve as a framework for testing other block explorer APIs. (Wei Chen) 6e648fd chore: update MSRV dependency for nightly docs (Wei Chen) Pull request description: ### Description `TestEnv` is extracted into its own crate with `electrsd` support added so that `TestEnv` can also serve `esplora` and `electrum`. The tests in the `esplora` crate have also been updated to use `TestEnv`. The `tx_can_become_unconfirmed_after_reorg()` test in `test_electrum` suggests that the electrum issue where a reorged tx would be stuck at confirmed does not exist anymore. ### Notes to the reviewers The code for `tx_can_become_unconfirmed_after_reorg()` was adapted from the same test in `bitcoind_rpc/test_emitter`. This electrum version of the test requires extra review, as I am uncertain if I used the API efficiently. #### All Submissions: * [x] I've signed all my commits * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md) * [x] I ran `cargo fmt` and `cargo clippy` before committing ACKs for top commit: evanlinjin: ACK 7c9ba3c Tree-SHA512: 36c6501e477abb7ae68073b6f4776f1f69f8964010ab758aa3677aae96df10f2cb632421872cacd73b37123d6db8a9dbefb5b6416e0dd524b712bf3fc56b7139
2 parents a837cd3 + 7c9ba3c commit 80e190b

File tree

13 files changed

+612
-334
lines changed

13 files changed

+612
-334
lines changed

.github/workflows/nightly_docs.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ jobs:
1717
run: rustup update
1818
- name: Rust Cache
1919
uses: Swatinem/[email protected]
20+
- name: Pin dependencies for MSRV
21+
run: cargo update -p home --precise "0.5.5"
2022
- name: Build docs
2123
run: cargo doc --no-deps
2224
env:

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ members = [
88
"crates/esplora",
99
"crates/bitcoind_rpc",
1010
"crates/hwi",
11+
"crates/testenv",
1112
"example-crates/example_cli",
1213
"example-crates/example_electrum",
1314
"example-crates/example_esplora",

crates/bitcoind_rpc/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ bitcoincore-rpc = { version = "0.17" }
1919
bdk_chain = { path = "../chain", version = "0.11", default-features = false }
2020

2121
[dev-dependencies]
22-
bitcoind = { version = "0.33", features = ["25_0"] }
22+
bdk_testenv = { path = "../testenv", default_features = false }
2323
anyhow = { version = "1" }
2424

2525
[features]

0 commit comments

Comments
 (0)