-
Notifications
You must be signed in to change notification settings - Fork 10
53 lines (46 loc) · 1.1 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: Tests
on:
pull_request:
branches:
- main
paths:
- "gym_pusht/**"
- "tests/**"
- "examples.py"
- ".github/**"
- "poetry.lock"
push:
branches:
- main
paths:
- "gym_pusht/**"
- "tests/**"
- "examples.py"
- ".github/**"
- "poetry.lock"
jobs:
pytest:
name: Pytest
runs-on: ubuntu-latest
env:
DATA_DIR: tests/data
MUJOCO_GL: egl
steps:
- uses: actions/checkout@v4
- name: Install EGL
run: sudo apt-get update && sudo apt-get install -y libegl1-mesa-dev
- name: Install poetry
run: |
pipx install poetry && poetry config virtualenvs.in-project true
echo "${{ github.workspace }}/.venv/bin" >> $GITHUB_PATH
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
cache: "poetry"
- name: Install poetry dependencies
run: |
poetry install --all-extras
- name: Test with pytest
run: |
pytest tests -v --cov=./gym_pusht --durations=0