Skip to content

add 'spend_pub' lmdb index for prekey bundle #126

add 'spend_pub' lmdb index for prekey bundle

add 'spend_pub' lmdb index for prekey bundle #126

Workflow file for this run

name: Unit Tests
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
test-rust:
name: Test Rust Core (tsarcore_native)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
- name: Run Rust tests
working-directory: ./tsarcore_native
run: cargo test
test-python:
name: Test Python Architecture
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Check for Test File Modifications in PR
if: github.event_name == 'pull_request'
run: |
git fetch origin main:main || true
MODIFIED_TESTS=$(git diff --name-only main...HEAD | grep -E '^tests/|^tsarcore_native/tests/' || true)
if [ -n "$MODIFIED_TESTS" ]; then
echo "::warning::PR attempts to modify unit test files:"
echo "$MODIFIED_TESTS"
echo "Unit test files must not be altered by external contributors without core maintainer approval."
fi
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.14'
- name: Install dependencies
run: |
sudo apt-get update && sudo apt-get install -y xvfb
python -m pip install --upgrade pip maturin
pip install ./tsarcore_native
pip install -r requirements.txt
- name: Run Python unit tests
run: |
xvfb-run -a env PYTHONPATH=src pytest