From 0bd41929b2f244c9a18fbe192c46f0d41bc0db13 Mon Sep 17 00:00:00 2001 From: Michael Gasch Date: Wed, 21 Apr 2021 10:52:55 +0200 Subject: [PATCH] chore: Verify PRs and push to main Add two action workflows to verify commits and PRs with unit and integration tests using Github Actions. Closes: #6 Signed-off-by: Michael Gasch --- .../ps-ce-sdk-integration-tests.yaml | 31 +++++++++++++++++++ .github/workflows/ps-ce-sdk-unit-tests.yaml | 31 +++++++++++++++++++ 2 files changed, 62 insertions(+) create mode 100644 .github/workflows/ps-ce-sdk-integration-tests.yaml create mode 100644 .github/workflows/ps-ce-sdk-unit-tests.yaml diff --git a/.github/workflows/ps-ce-sdk-integration-tests.yaml b/.github/workflows/ps-ce-sdk-integration-tests.yaml new file mode 100644 index 0000000..bdcdd8d --- /dev/null +++ b/.github/workflows/ps-ce-sdk-integration-tests.yaml @@ -0,0 +1,31 @@ +# ************************************************************************** +# Copyright (c) Cloud Native Foundation. +# SPDX-License-Identifier: Apache-2.0 +# ************************************************************************** + +name: Integration Tests + +on: + push: + branches: ["main"] + + pull_request: + branches: ["main"] + +jobs: + integration-tests: + name: Run Integration Tests + strategy: + matrix: + platform: ["ubuntu-latest", "windows-latest"] + + runs-on: ${{ matrix.platform }} + timeout-minutes: 10 + + steps: + - name: Check out code + uses: actions/checkout@v2 + + - name: Run Tests + shell: pwsh + run: ./build.ps1 -TestsType integration -ExitProcess diff --git a/.github/workflows/ps-ce-sdk-unit-tests.yaml b/.github/workflows/ps-ce-sdk-unit-tests.yaml new file mode 100644 index 0000000..94346be --- /dev/null +++ b/.github/workflows/ps-ce-sdk-unit-tests.yaml @@ -0,0 +1,31 @@ +# ************************************************************************** +# Copyright (c) Cloud Native Foundation. +# SPDX-License-Identifier: Apache-2.0 +# ************************************************************************** + +name: Unit Tests + +on: + push: + branches: ["main"] + + pull_request: + branches: ["main"] + +jobs: + unit-tests: + name: Run Unit Tests + strategy: + matrix: + platform: ["ubuntu-latest", "windows-latest"] + + runs-on: ${{ matrix.platform }} + timeout-minutes: 10 + + steps: + - name: Check out code + uses: actions/checkout@v2 + + - name: Run Tests + shell: pwsh + run: ./build.ps1 -TestsType unit -ExitProcess