diff --git a/.github/workflows/Xcode_build_test.yml b/.github/workflows/Xcode_build_test.yml index 55cb271..53fd484 100644 --- a/.github/workflows/Xcode_build_test.yml +++ b/.github/workflows/Xcode_build_test.yml @@ -75,6 +75,8 @@ jobs: outputs: matrix: ${{ steps.generate-test-matrix.outputs.matrix }} steps: + - uses: actions/checkout@v4 + - name: Generate test matrix id: generate-test-matrix run: | diff --git a/test b/test new file mode 100755 index 0000000..f54af08 --- /dev/null +++ b/test @@ -0,0 +1,16 @@ +#!/bin/sh + +matrix="{\"include\":[" +first_entry=true +for scheme in $(xcodebuild -workspace iOS/MusicSpot.xcworkspace -list | grep -A 100 "Schemes:" | grep -v "Schemes:" | sed '/^$/d' | sed 's/^[ \t]*//'); do + if [[ $scheme == *"Tests" ]]; then + if [ "$first_entry" = true ]; then + first_entry=false + else + matrix+="," + fi + matrix+="{\"scheme\":\"$scheme\"}" + fi +done +matrix+="]}" +echo $matrix \ No newline at end of file