fixup! Add end-to-end test for HRN resolution #71
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI Checks - HRN Integration Tests | |
| on: [push, pull_request] | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| build-and-test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout source code | |
| uses: actions/checkout@v3 | |
| - name: Install Rust stable toolchain | |
| run: | | |
| curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile=minimal --default-toolchain stable | |
| - name: Enable caching for bitcoind | |
| id: cache-bitcoind | |
| uses: actions/cache@v4 | |
| with: | |
| path: bin/bitcoind-${{ runner.os }}-${{ runner.arch }} | |
| key: bitcoind-29.0-${{ runner.os }}-${{ runner.arch }} | |
| - name: Enable caching for electrs | |
| id: cache-electrs | |
| uses: actions/cache@v4 | |
| with: | |
| path: bin/electrs-${{ runner.os }}-${{ runner.arch }} | |
| key: electrs-${{ runner.os }}-${{ runner.arch }} | |
| - name: Download bitcoind/electrs | |
| if: "steps.cache-bitcoind.outputs.cache-hit != 'true' || steps.cache-electrs.outputs.cache-hit != 'true'" | |
| run: | | |
| source ./scripts/download_bitcoind_electrs.sh | |
| mkdir -p bin | |
| mv "$BITCOIND_EXE" bin/bitcoind-${{ runner.os }}-${{ runner.arch }} | |
| mv "$ELECTRS_EXE" bin/electrs-${{ runner.os }}-${{ runner.arch }} | |
| - name: Set bitcoind/electrs environment variables | |
| run: | | |
| echo "BITCOIND_EXE=$( pwd )/bin/bitcoind-${{ runner.os }}-${{ runner.arch }}" >> "$GITHUB_ENV" | |
| echo "ELECTRS_EXE=$( pwd )/bin/electrs-${{ runner.os }}-${{ runner.arch }}" >> "$GITHUB_ENV" | |
| - name: Run HRN Integration Tests | |
| run: | | |
| RUSTFLAGS="--cfg no_download --cfg hrn_tests $RUSTFLAGS" cargo test --test integration_tests_hrn | |
| RUSTFLAGS="--cfg no_download --cfg hrn_tests $RUSTFLAGS" cargo test --test integration_tests_hrn --features uniffi |