-
Notifications
You must be signed in to change notification settings - Fork 31
48 lines (39 loc) · 1.18 KB
/
berserk.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
name: Berserk Validation
on:
push:
workflow_dispatch:
jobs:
engine:
name: Berserk on ${{matrix.os}} with gcc-${{matrix.version}}
runs-on: ${{matrix.os}}
strategy:
matrix:
os: [ubuntu-20.04]
version: [11]
steps:
- name: Set up GCC ${{matrix.version}}
uses: egor-tensin/setup-gcc@v1
with:
version: ${{matrix.version}}
platform: x64
- name: Clone Berserk
uses: actions/checkout@v2
- name: Compile
run: cd src && make build ARCH=avx2
- name: Bench
run: |
bench=$(git show --summary | grep -Po '(?<=Bench: )[0-9]+?(?=$)')
./src/berserk bench > output
real=$(grep 'Results:' output | grep -Po '(?<=[\s]{5})[0-9]+?(?= nodes)')
if [[ "$bench" != "$real" ]]; then echo "got $real, expected $bench" && exit 1; fi
- name: Install Expect
run: sudo apt-get install -y expect
- name: Perft Test
run: ./tests/perft.sh 1>/dev/null
clang-format-checking:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: RafikFarhad/[email protected]
with:
sources: 'src/*.c,src/*.h'