-
Notifications
You must be signed in to change notification settings - Fork 402
53 lines (49 loc) · 1.47 KB
/
test.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
name: Test
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:
jobs:
tests-and-coverage-pip:
name: Test & Coverage (pip)
uses: ./.github/workflows/reusable_test_pip.yml
with:
use_latest_pytorch_gpytorch: true
secrets: inherit
tests-conda:
name: Tests (conda, ${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: ["ubuntu-latest", "macos-14", "windows-latest"]
python-version: ["3.10", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: conda-incubator/setup-miniconda@v3
with:
miniconda-version: "latest"
activate-environment: test
python-version: ${{ matrix.python-version }}
- name: Install dependencies
shell: bash -l {0}
env:
ALLOW_LATEST_GPYTORCH_LINOP: true
run: |
# avoid conda bug in >=23.10.0: https://github.com/conda/conda/issues/13412
conda config --set solver classic
conda install pytorch torchvision -c pytorch
conda install -y pip scipy sphinx pytest flake8
pip install git+https://github.com/cornellius-gp/linear_operator.git
pip install git+https://github.com/cornellius-gp/gpytorch.git
pip install .[test]
- name: Unit tests -- BoTorch
shell: bash -l {0}
run: |
pytest -ra test/
- name: Unit tests -- BoTorch Community
shell: bash -l {0}
run: |
pytest -ra test_community/