Skip to content

Commit ce98846

Browse files
Joseph-Edwardsjames-d-mitchell
authored andcommitted
Test with conda libsemigroups
1 parent c25dd8d commit ce98846

1 file changed

Lines changed: 65 additions & 0 deletions

File tree

.github/workflows/test-conda.yml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: Run tests (Conda libsemigroups)
2+
on: [pull_request, workflow_dispatch]
3+
4+
concurrency:
5+
group: ${{ github.workflow }}-${{ github.ref }}
6+
cancel-in-progress: true
7+
8+
jobs:
9+
check-doc:
10+
name: ${{ matrix.os }}
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
include:
15+
- os: ubuntu-latest
16+
compiler: g++
17+
- os: macOS-latest
18+
compiler: clang++
19+
runs-on: ${{ matrix.os }}
20+
timeout-minutes: 15
21+
defaults:
22+
run:
23+
shell: bash -l {0}
24+
env:
25+
CXX: "ccache ${{ matrix.compiler }}"
26+
UV_NO_SYNC: "1"
27+
steps:
28+
# Setup environment
29+
- uses: actions/checkout@v5
30+
- name: Create micromamba environment . . .
31+
uses: mamba-org/setup-micromamba@v2
32+
with:
33+
environment-name: libsemigroups
34+
cache-environment: true
35+
create-args: >-
36+
python
37+
libsemigroups
38+
- name: Install uv . . .
39+
uses: astral-sh/setup-uv@v6
40+
with:
41+
enable-cache: true
42+
- name: Setup ccache . . .
43+
uses: Chocobo1/setup-ccache-action@v1
44+
with:
45+
update_packager_index: false
46+
install_ccache: true
47+
- name: Set environment variables . . .
48+
run: |
49+
echo "PKG_CONFIG_PATH=$MAMBA_ROOT_PREFIX/envs/libsemigroups/lib/pkgconfig:$MAMBA_ROOT_PREFIX/envs/libsemigroups/share/pkgconfig:/usr/local/lib/pkgconfig" >> $GITHUB_ENV
50+
echo "PATH=$MAMBA_ROOT_PREFIX/envs/libsemigroups/bin:$PATH" >> $GITHUB_ENV
51+
- name: Check Python version . . .
52+
run: python --version
53+
54+
# Build libsemigroups_pybind11
55+
- name: "Install libsemigroups_pybind11 . . ."
56+
run: uv sync --locked --all-extras --no-dev --group lint
57+
58+
# Run the tests and lint
59+
- name: "Running tests . . ."
60+
run: uv run pytest
61+
- name: "Running doc tests . . ."
62+
run: |
63+
uv run etc/make-doc.sh # so that all files are generated!
64+
cd docs
65+
uv run python -m sphinx -b doctest -d _build/doctrees source _build/doctest

0 commit comments

Comments
 (0)