-
Notifications
You must be signed in to change notification settings - Fork 2
62 lines (53 loc) · 1.69 KB
/
internal-validate-workflow-files.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: ⚙️ Validate Workflow Files
on:
push:
branches:
- 'main'
pull_request:
branches:
- 'main'
workflow_dispatch:
jobs:
validate-workflow-files:
name: Validate Workflow Files
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Install QLT
id: install-qlt
uses: ./.github/actions/install-qlt-local
with:
qlt-version: 'latest'
add-to-path: true
- name: Validate QLT Installation
shell: bash
run: |
echo -e "Checking QLT Version:"
echo "QLT Home: ${{ steps.install-qlt.outputs.qlt-home }}"
qlt version
- name: Generate Workflow Files (Test Feature)
shell: bash
run: |
if ! qlt test init --use-runner ubuntu-latest --num-threads 4 --language cpp --automation-type actions --development --overwrite-existing ; then
echo "Failed to generate test workflow files."
exit 1
fi
- name: Generate Workflow Files (Validation Feature)
shell: bash
run: |
if ! qlt validation init --use-runner ubuntu-latest --language cpp --automation-type actions --development --overwrite-existing ; then
echo "Failed to generate validation workflow files."
exit 1
fi
- name: Check Git Clean Status
shell: bash
run: |
if git diff --quiet .github ; then
echo "Git is clean - generation is as expected."
else
echo "Some files have changed - please check for regressions."
git status
git diff .github
exit 1
fi