Refactor GitHub Actions workflows for PHPVM: streamline job configura… #52
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
test: | |
strategy: | |
matrix: | |
os: [macos-latest, ubuntu-latest] # Run tests on both MacOS & Ubuntu | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
- name: Install Dependencies | |
run: | | |
if [[ "$RUNNER_OS" == "Linux" ]]; then | |
sudo apt update | |
sudo apt install -y bats | |
else | |
brew install bats | |
fi | |
- name: Run PHPVM Tests | |
run: | | |
bats test_phpvm.bats |