Skip to content

Commit f7443ac

Browse files
committed
Gate set_test_offer and add HRN test config
1 parent d8f6cf5 commit f7443ac

File tree

4 files changed

+16
-7
lines changed

4 files changed

+16
-7
lines changed

.github/workflows/kotlin.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ jobs:
1313
env:
1414
LDK_NODE_JVM_DIR: bindings/kotlin/ldk-node-jvm
1515
LDK_NODE_ANDROID_DIR: bindings/kotlin/ldk-node-android
16+
RUSTFLAGS: "--cfg hrn_tests"
1617

1718
steps:
1819
- name: Checkout repository

.github/workflows/python.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
uses: astral-sh/setup-uv@v7
2222

2323
- name: Generate Python bindings
24-
run: ./scripts/uniffi_bindgen_generate_python.sh
24+
run: RUSTFLAGS="--cfg hrn_tests" ./scripts/uniffi_bindgen_generate_python.sh
2525

2626
- name: Start bitcoind and electrs
2727
run: docker compose up -d

.github/workflows/rust.yml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -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

.github/workflows/swift.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ jobs:
1818
run: rustup default stable
1919

2020
- name: Generate Swift bindings
21-
run: ./scripts/uniffi_bindgen_generate_swift.sh
21+
run: RUSTFLAGS="--cfg hrn_tests" ./scripts/uniffi_bindgen_generate_swift.sh

0 commit comments

Comments
 (0)