Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix perft-test.yml workflow #26

Merged
merged 2 commits into from
Oct 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 19 additions & 8 deletions .github/workflows/perft-test.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,39 @@
name: Run perft tests

on:
workflow_call:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
build-and-test:
perft-test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]

steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Checkout code
uses: actions/checkout@v2

- name: Install Dependencies
run: |
sudo apt-get update || brew update
sudo apt-get install -y build-essential || brew install make
if [[ "$RUNNER_OS" == "Linux" ]]; then
sudo apt-get update
sudo apt-get install -y build-essential
elif [[ "$RUNNER_OS" == "macOS" ]]; then
brew update
brew install make
fi

- name: Build Sonic
working-directory: Sonic/src
working-directory: src
run: make

- name: Run perft tests
working-directory: Sonic/src
working-directory: src
run: |
echo -e "perft\nquit" | ./sonic
Loading