Swift: split quick tests in separate action

Also, make the quick test list explicit in the action code, so we can
catch an inadvertant test deletion.
This commit is contained in:
Paolo Tranquilli
2022-11-02 14:32:45 +01:00
parent 57a616262f
commit e6d4685109
3 changed files with 24 additions and 4 deletions

View File

@@ -45,16 +45,18 @@ jobs:
- 'swift/**/*.qll'
# not using a matrix as you cannot depend on a specific job in a matrix, and we want to start linux checks
# without waiting for the macOS build
build-macos:
build-and-test-macos:
runs-on: macos-12-xl
steps:
- uses: actions/checkout@v3
- uses: ./swift/actions/create-and-test-extractor-pack
build-linux:
- uses: ./swift/actions/create-extractor-pack
- uses: ./swift/actions/run-quick-tests
build-and-test-linux:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: ./swift/actions/create-and-test-extractor-pack
- uses: ./swift/actions/create-extractor-pack
- uses: ./swift/actions/run-quick-tests
qltests-linux:
needs: build-linux
runs-on: ubuntu-latest

View File

@@ -0,0 +1,18 @@
name: Run Swift quick tests
description: Runs Swift tests defined in Bazel. Must be run after `setup-env`
runs:
using: composite
steps:
- name: Run xcode-autobuilder tests
if: ${{ runner.os == "macOS" }}
shell: bash
run: |
bazel test //swift/xcode-autobuilder/tests
- name: Run codegen tests
shell: bash
run: |
bazel test //swift/codegen/tests
- name: Run qltest tests
shell: bash
run: |
bazel test //swift/tools/test/qltest