From 04f75f9706b22d106ecc431e91281bbc60417e07 Mon Sep 17 00:00:00 2001 From: Brandon <32753167+btoms20@users.noreply.github.com> Date: Thu, 8 Feb 2024 21:41:10 -0800 Subject: [PATCH] Update build+test.yml --- .github/workflows/build+test.yml | 36 ++++++++++++++++---------------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/.github/workflows/build+test.yml b/.github/workflows/build+test.yml index 5890ee8..2ce8395 100644 --- a/.github/workflows/build+test.yml +++ b/.github/workflows/build+test.yml @@ -1,31 +1,31 @@ -name: Build & Test (macos & linux) +name: Build & Test on: push: + paths-ignore: + - 'README.md' branches: [ main ] pull_request: + paths-ignore: + - 'README.md' branches: [ main ] jobs: - build-macos: - - runs-on: macos-latest - - steps: - - uses: actions/checkout@v3 - - name: Build - run: swift build -v - - name: Run tests - run: swift test -v - - build-linux: - - runs-on: ubuntu-latest - + test-matrix: + if: ${{ !(github.event.pull_request.draft || false) }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] + swift-version: ["5.9", "5.8", "5.7"] + runs-on: ${{ matrix.os }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: swift-actions/setup-swift@v1 + with: + swift-version: ${{ matrix.swift-version }} + - name: Get swift version + run: swift --version - name: Build run: swift build -v - - name: Run tests + - name: Test run: swift test -v