@@ -72,23 +72,31 @@ jobs:
7272 echo "BITCOIND_EXE=$( pwd )/bin/bitcoind-${{ runner.os }}-${{ runner.arch }}" >> "$GITHUB_ENV"
7373 echo "ELECTRS_EXE=$( pwd )/bin/electrs-${{ runner.os }}-${{ runner.arch }}" >> "$GITHUB_ENV"
7474 - name : Build on Rust ${{ matrix.toolchain }}
75+ env :
76+ RUSTFLAGS : " --cfg hrn_tests"
7577 run : cargo build --verbose --color always
7678 - name : Build with UniFFI support on Rust ${{ matrix.toolchain }}
7779 if : matrix.build-uniffi
80+ env :
81+ RUSTFLAGS : " --cfg hrn_tests"
7882 run : cargo build --features uniffi --verbose --color always
7983 - name : Check release build on Rust ${{ matrix.toolchain }}
84+ env :
85+ RUSTFLAGS : " --cfg hrn_tests"
8086 run : cargo check --release --verbose --color always
8187 - name : Check release build with UniFFI support on Rust ${{ matrix.toolchain }}
8288 if : matrix.build-uniffi
89+ env :
90+ RUSTFLAGS : " --cfg hrn_tests"
8391 run : cargo check --release --features uniffi --verbose --color always
8492 - name : Test on Rust ${{ matrix.toolchain }}
8593 if : " matrix.platform != 'windows-latest'"
8694 run : |
87- RUSTFLAGS="--cfg no_download --cfg cycle_tests" cargo test
95+ RUSTFLAGS="--cfg no_download --cfg cycle_tests --cfg hrn_tests " cargo test
8896 - name : Test with UniFFI support on Rust ${{ matrix.toolchain }}
8997 if : " matrix.platform != 'windows-latest' && matrix.build-uniffi"
9098 run : |
91- RUSTFLAGS="--cfg no_download --cfg cycle_tests" cargo test --features uniffi
99+ RUSTFLAGS="--cfg no_download --cfg cycle_tests --cfg hrn_tests " cargo test --features uniffi
92100
93101 linting :
94102 name : Linting
@@ -102,14 +110,14 @@ jobs:
102110 rustup component add clippy
103111 - name : Ban `unwrap` in library code
104112 run : |
105- cargo clippy --lib --verbose --color always -- -A warnings -D clippy::unwrap_used -A clippy::tabs_in_doc_comments
106- cargo clippy --lib --features uniffi --verbose --color always -- -A warnings -D clippy::unwrap_used -A clippy::tabs_in_doc_comments
113+ RUSTFLAGS="--cfg hrn_tests" cargo clippy --lib --verbose --color always -- -A warnings -D clippy::unwrap_used -A clippy::tabs_in_doc_comments
114+ RUSTFLAGS="--cfg hrn_tests" cargo clippy --lib --features uniffi --verbose --color always -- -A warnings -D clippy::unwrap_used -A clippy::tabs_in_doc_comments
107115
108116 doc :
109117 name : Documentation
110118 runs-on : ubuntu-latest
111119 env :
112- RUSTDOCFLAGS : -Dwarnings
120+ RUSTDOCFLAGS : " -Dwarnings --cfg hrn_tests "
113121 steps :
114122 - uses : actions/checkout@v6
115123 - uses : dtolnay/rust-toolchain@nightly
0 commit comments