WIP: Validate individual tasks/stepactions #7
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run Task Tests | |
"on": | |
pull_request | |
jobs: | |
run-task-tests: | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Free Disk Space | |
uses: jlumbroso/free-disk-space@main | |
with: | |
tool-cache: false | |
docker-images: false | |
- name: Get all changed task files | |
id: changed-tasks-files | |
uses: tj-actions/changed-files@v45 | |
with: | |
# Avoid using single or double quotes for multiline patterns | |
files: | | |
task/** | |
test/** | |
- name: List all changed tasks | |
if: steps.changed-tasks-files.outputs.any_changed == 'true' | |
env: | |
ALL_CHANGED_FILES: ${{ steps.changed-tasks-files.outputs.all_changed_files }} | |
run: | | |
for file in ${ALL_CHANGED_FILES}; do | |
echo "$file was changed" | |
done | |
- name: Checkout build-defintions Repository | |
uses: actions/checkout@v3 | |
with: | |
ref: "${{ github.event.pull_request.head.sha }}" | |
path: build-definitions | |
- name: Checkout konflux-ci/konflux-ci Repository | |
uses: actions/checkout@v3 | |
with: | |
repository: 'konflux-ci/konflux-ci' | |
path: konflux-ci | |
- name: Create k8s Kind Cluster | |
uses: helm/kind-action@v1 | |
with: | |
config: konflux-ci/kind-config.yaml | |
- name: Show version information | |
run: | | |
kubectl version | |
kind version | |
- name: Deploying Dependencies | |
run: | | |
cd $GITHUB_WORKSPACE/konflux-ci | |
./deploy-deps.sh | |
- name: Wait for the dependencies to be ready | |
run: | | |
cd $GITHUB_WORKSPACE/konflux-ci | |
./wait-for-all.sh | |
- name: Deploying Konflux | |
run: | | |
cd $GITHUB_WORKSPACE/konflux-ci | |
./deploy-konflux.sh | |
- name: List namespaces | |
run: | | |
kubectl get namespace | |
- name: Deploy test resources | |
run: | | |
cd $GITHUB_WORKSPACE/konflux-ci | |
./deploy-test-resources.sh | |
- name: Run git-clone task test | |
run: | | |
cd $GITHUB_WORKSPACE/build-definitions | |
./hack/run-test.sh task git-clone 0.1 |