From c29d552a7a353631e2e0ebcee87d56ac474382be Mon Sep 17 00:00:00 2001 From: Janos Bonic <86970079+janosdebugs@users.noreply.github.com> Date: Fri, 22 Dec 2023 20:21:56 +0100 Subject: [PATCH] Matrix test Signed-off-by: Janos Bonic <86970079+janosdebugs@users.noreply.github.com> --- .github/workflows/test.yml | 16 ++++++++++++++-- tests/macos/{test.sh => auto.sh} | 0 tests/macos/brew.sh | 7 +++++++ tests/macos/portable.sh | 7 +++++++ 4 files changed, 28 insertions(+), 2 deletions(-) rename tests/macos/{test.sh => auto.sh} (100%) create mode 100755 tests/macos/brew.sh create mode 100755 tests/macos/portable.sh diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 41a4238..6100d7f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -5,20 +5,32 @@ jobs: linux: name: Linux runs-on: ubuntu-latest + strategy: + matrix: + distro: [alpine, debian, fedora, opensuse, rocky, ubuntu] + method: [auto, brew, manual, portable, snap] + shell: [ash, bash, dash, ksh, zsh] steps: - name: Checkout uses: actions/checkout@v4 - name: Test + env: + DISTRO: ${{ matrix.distro }} + METHOD: ${{ matrix.method }} + SH: ${{ matrix.shell }} run: | cd tests/linux - ./test-all.sh + ./test.sh macos: name: MacOS runs-on: macos-latest + strategy: + matrix: + method: [auto, brew, portable] steps: - name: Checkout uses: actions/checkout@v4 - name: Test run: | cd tests/macos - ./test.sh \ No newline at end of file + ./${{ matrix.method }}.sh \ No newline at end of file diff --git a/tests/macos/test.sh b/tests/macos/auto.sh similarity index 100% rename from tests/macos/test.sh rename to tests/macos/auto.sh diff --git a/tests/macos/brew.sh b/tests/macos/brew.sh new file mode 100755 index 0000000..26ac752 --- /dev/null +++ b/tests/macos/brew.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +set -ex + +../../src/install.sh --debug --install-method "brew" + +tofu --version \ No newline at end of file diff --git a/tests/macos/portable.sh b/tests/macos/portable.sh new file mode 100755 index 0000000..c23af59 --- /dev/null +++ b/tests/macos/portable.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +set -ex + +../../src/install.sh --debug --install-method "portable" + +tofu --version \ No newline at end of file