Skip to content

Commit

Permalink
ci: Add tft plan and workflow
Browse files Browse the repository at this point in the history
This change is for running tests in Testing Farm CI. This is a replacement for
BaseOS CI that we are currently using. Running it Testing Farm gives us more
control.

It adds a workflow for running tests, and a plans directory containing a test
plan and a README-plans.md with some info.

Note that this workflow runs from the main branch. This means that changes to
the workflow must be merged to main, then pull requests will be able to run it.
This is because the workflow uses on: issue_comment context, this is a security
measure recommended by GitHub. It saves us from leaking organization secrets.

The functionality is WIP, so await future fixes and updates.

Signed-off-by: Sergei Petrosian <spetrosi@redhat.com>
  • Loading branch information
spetrosi committed Jul 25, 2024
1 parent 77cde49 commit cb53b08
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/tft.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Testing Farm
name: Run integration tests in Testing Farm
on:
issue_comment:
types:
Expand All @@ -14,7 +14,7 @@ concurrency:
cancel-in-progress: true
jobs:
prepare_vars:
name: Get supported platforms from meta/main.yml
name: Get info from role and PR to determine if and how to test
# Let's schedule tests only on user request. NOT automatically.
# Only repository owner or member can schedule tests
if: |
Expand Down Expand Up @@ -136,7 +136,8 @@ jobs:
description: The role does not support this platform. Skipping.
targetUrl: ""

- uses: sclorg/testing-farm-as-github-action@v2
- name: Run test in testing farm
uses: sclorg/testing-farm-as-github-action@v2
if: contains(needs.prepare_vars.outputs.supported_platforms, matrix.platform)
env:
ARTIFACTS_DIR: ${{ env.ARTIFACT_TARGET_DIR }}/${{ env.ARTIFACTS_DIR_NAME }}
Expand Down

0 comments on commit cb53b08

Please sign in to comment.