Skip to content

Refactor repo structure to prepare addition of a Rust recorder #13

Refactor repo structure to prepare addition of a Rust recorder

Refactor repo structure to prepare addition of a Rust recorder #13

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
tests:
name: Tests on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Run tests
shell: bash
run: python -m unittest discover -v
nix-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v27
with:
nix_path: nixpkgs=channel:nixos-24.05
extra_nix_config: |
experimental-features = nix-command flakes
- name: Run tests via Nix
run: nix develop --command just test
rust-smoke:
name: Rust module smoke test on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.x'
- uses: messense/maturin-action@v1
with:
command: build
args: -m crates/codetracer-python-recorder/Cargo.toml --release
- name: Install built wheel
run: python -m pip install --upgrade pip && python -m pip install target/wheels/*.whl
- name: Import smoke test
run: python -c "import codetracer_python_recorder as m; print(m.hello())"