fix: restore relation module — required by aura.rs public API #62
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: Tests | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| env: | |
| CARGO_TERM_COLOR: always | |
| CARGO_INCREMENTAL: 0 | |
| jobs: | |
| rust-tests: | |
| name: Rust Tests | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 60 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| with: | |
| cache-on-failure: true | |
| - name: Build library tests | |
| run: cargo test --lib --no-default-features --features "encryption,audit" --no-run 2>&1 | tail -5 | |
| - name: Run library tests | |
| run: cargo test --lib --no-default-features --features "encryption,audit" -- --test-threads=2 | |
| - name: Cargo check | |
| run: cargo check --no-default-features --features "encryption,audit" | |
| python-tests: | |
| name: Python Tests (${{ matrix.os }}, ${{ matrix.python-version }}) | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 30 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| python-version: ["3.9", "3.12"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Create venv and install deps | |
| run: | | |
| python -m venv .venv | |
| .venv/bin/pip install maturin pytest pytest-timeout | |
| if: runner.os != 'Windows' | |
| - name: Create venv and install deps (Windows) | |
| run: | | |
| python -m venv .venv | |
| .venv\Scripts\pip install maturin pytest pytest-timeout | |
| if: runner.os == 'Windows' | |
| - name: Build and install | |
| run: .venv/bin/maturin develop --release --features "pyo3/extension-module,encryption" | |
| if: runner.os != 'Windows' | |
| - name: Build and install (Windows) | |
| run: .venv\Scripts\maturin develop --release --features "pyo3/extension-module,encryption" | |
| if: runner.os == 'Windows' | |
| - name: Run Python smoke | |
| run: | | |
| .venv/bin/python -c "from aura import Aura, Level; b = Aura('./ci_smoke_brain'); b.store('User prefers dark mode', level=Level.Identity, tags=['ui'], semantic_type='preference'); r = b.recall('dark mode'); assert r and 'dark mode' in r.lower()" | |
| if: runner.os != 'Windows' | |
| - name: Run Python smoke (Windows) | |
| run: | | |
| .venv\Scripts\python -c "from aura import Aura, Level; b = Aura('./ci_smoke_brain'); b.store('User prefers dark mode', level=Level.Identity, tags=['ui'], semantic_type='preference'); r = b.recall('dark mode'); assert r and 'dark mode' in r.lower()" | |
| if: runner.os == 'Windows' |