Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:

steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.74.1
- uses: dtolnay/rust-toolchain@1.90.0
with:
components: rustfmt, clippy

Expand Down
26 changes: 24 additions & 2 deletions .github/workflows/functional.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,39 +7,48 @@ on:

jobs:
functional:
name: Functional
name: Functional ${{ matrix.type }}
runs-on: ubuntu-latest
strategy:
matrix:
type: [python, rust]

steps:
- uses: actions/checkout@v4

# These are the minimal deps defined by bitcoin core at
# https://github.com/bitcoin/bitcoin/blob/master/doc/build-unix.md
- name: Prepare bitcoin-core deps
if: matrix.type == 'python'
run: sudo apt install build-essential cmake pkgconf python3 libevent-dev libboost-dev

# see more at
# https://docs.astral.sh/uv/guides/integration/github/
- name: Install uv
if: matrix.type == 'python'
uses: astral-sh/setup-uv@v5
with:
python-version: "3.12"
enable-cache: true
cache-dependency-glob: "uv.lock"

- name: Prepare environment
if: matrix.type == 'python'
run: uv sync --all-extras --dev

- name: Run black formatting
if: matrix.type == 'python'
run: uv run black --check --verbose ./tests

- name: Run pylint linter
if: matrix.type == 'python'
run: uv run pylint --verbose ./tests

- name: Cache Rust
uses: Swatinem/rust-cache@v2

- name: Run functional tests tasks
- name: Prepare and run functional tests in python
if: matrix.type == 'python'
run: |
tests/prepare.sh
tests/run.sh
Expand All @@ -57,3 +66,16 @@ jobs:
cat "$logfile" || echo "Failed to read $logfile"
echo "::endgroup::"
done

- name: Prepare Bitcoind and Utreexod binaries
if: matrix.type == 'rust'
run: |
source ./test-rust/scripts/prepare.sh
echo "BITCOIND_EXE=$BITCOIND_EXE" >> "$GITHUB_ENV"
echo "UTREEXOD_EXE=$UTREEXOD_EXE" >> "$GITHUB_ENV"

- name: Build and test Rust
if: matrix.type == 'rust'
run: |
cargo build --bin florestad --release
cargo test --features=functional-tests -p test-functional -- --test-threads=1
2 changes: 1 addition & 1 deletion .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.74.1 # The version in our `rust-toolchain.toml`
- uses: dtolnay/rust-toolchain@1.90.0 # The version in our `rust-toolchain.toml`
with:
components: rustfmt, clippy
- uses: taiki-e/install-action@cargo-hack
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ When adding a new feature ensure that it is covered by functional tests where po
When refactoring, structure your PR to make it easy to review and don't
hesitate to split it into multiple small, focused PRs.

The Minimum Supported Rust Version is **1.74.1** (enforced by our CI).
The Minimum Supported Rust Version is **1.90.0** (enforced by our CI).

Commits should cover both the issue fixed and the solution's rationale.

Expand Down
Loading