-
-
Notifications
You must be signed in to change notification settings - Fork 530
67 lines (65 loc) · 2.55 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: Test
on: [push, pull_request]
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- run: .github/workflows/setup-${{ matrix.os }}.sh
shell: bash
- run: pip install -e .
- run: python test.py -v
perft:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: "3.12"
- run: pip install -e .
- run: python examples/perft/perft.py -t 1 examples/perft/random.perft --max-nodes 10000
- run: python examples/perft/perft.py -t 1 examples/perft/chess960.perft --max-nodes 100000
- run: python examples/perft/perft.py -t 1 examples/perft/tricky.perft
- run: python examples/perft/perft.py -t 1 --variant giveaway examples/perft/giveaway.perft
- run: python examples/perft/perft.py -t 1 --variant atomic examples/perft/atomic.perft
- run: python examples/perft/perft.py -t 1 --variant racingkings examples/perft/racingkings.perft
- run: python examples/perft/perft.py -t 1 --variant horde examples/perft/horde.perft
- run: python examples/perft/perft.py -t 1 --variant crazyhouse examples/perft/crazyhouse.perft
- run: python examples/perft/perft.py -t 1 --variant 3check examples/perft/3check.perft
typing:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
python-version: ["3.9", "3.10", "3.11", "3.12"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- run: pip install -e .
- run: pip install mypy
- run: python -m mypy --strict chess
- run: python -m mypy --strict examples/**/*.py
- run: pip install pyright
- run: python -m pyright chess
- run: python -m pyright examples/**/*.py
readme:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: "3.12"
- run: sudo apt-get update && sudo apt-get install -y docutils-common
- run: python setup.py --long-description | rst2html --strict --no-raw > /dev/null
- run: pip install -e .
- run: .github/workflows/setup-ubuntu-latest.sh
- run: python -m doctest README.rst