-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (51 loc) · 1.58 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
name: CI
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
jobs:
standard:
strategy:
fail-fast: false
matrix:
runs-on: [ubuntu-latest, macos-latest, windows-latest]
include:
- runs-on: ubuntu-latest
config: -DCMAKE_BUILD_TYPE=Release -DUSE_ASSERT=1 -DBUILD_ALL=1
- runs-on: macos-latest
config: -DCMAKE_BUILD_TYPE=Release -DUSE_ASSERT=1 -DBUILD_ALL=1
- runs-on: windows-latest
config: -DCMAKE_BUILD_TYPE=Release -DUSE_ASSERT=1 -DBUILD_ALL=1 -G Ninja
defaults:
run:
shell: bash -l {0}
name: ${{ matrix.runs-on }} • x64 ${{ matrix.args }}
runs-on: ${{ matrix.runs-on }}
steps:
- name: Basic GitHub action setup
uses: actions/checkout@v2
- name: Set conda environment
uses: mamba-org/provision-with-micromamba@main
with:
environment-file: environment.yaml
environment-name: myenv
cache-env: true
extra-specs: |
python-prrng
- name: Set dummy version
run: echo "SETUPTOOLS_SCM_PRETEND_VERSION=0.0" >> $GITHUB_ENV
- name: Configure using CMake
run: cmake -Bbuild ${{ matrix.config }}
- name: Build doxygen-docs (error on warning)
if: runner.os == 'Linux'
working-directory: build
run: make html
- name: Build C++ ${{ matrix.prop }}
working-directory: build
run: cmake --build .
- name: Build and install Python module
run: python -m pip install .
- name: Run Python tests
run: python -m unittest discover tests -v