-
Notifications
You must be signed in to change notification settings - Fork 5
73 lines (69 loc) · 2.24 KB
/
codex-plugin-scanner.yml
File metadata and controls
73 lines (69 loc) · 2.24 KB
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
61
62
63
64
65
66
67
68
69
70
71
72
73
name: Codex Plugin Quality Gate
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
scan:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
timeout-minutes: 10
permissions:
contents: read
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
- name: Codex plugin scanner
uses: hashgraph-online/hol-codex-plugin-scanner-action@b45d6b583afe05819b24edc8e6418c9ad2e1f1d0 # v1
with:
# The pinned action resolves .codex-plugin/plugin.json from the repo root.
plugin_dir: "."
min_score: "70"
scan-regression:
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
fixture: good
plugin_dir: ".github/plugin-scanner-fixtures/good"
expect_outcome: success
- os: ubuntu-latest
fixture: bad
plugin_dir: ".github/plugin-scanner-fixtures/bad"
expect_outcome: failure
- os: windows-latest
fixture: good
plugin_dir: ".github/plugin-scanner-fixtures/good"
expect_outcome: success
- os: windows-latest
fixture: bad
plugin_dir: ".github/plugin-scanner-fixtures/bad"
expect_outcome: failure
runs-on: ${{ matrix.os }}
timeout-minutes: 10
permissions:
contents: read
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
- name: Codex plugin scanner regression
id: scan
continue-on-error: true
uses: hashgraph-online/hol-codex-plugin-scanner-action@b45d6b583afe05819b24edc8e6418c9ad2e1f1d0 # v1
with:
plugin_dir: ${{ matrix.plugin_dir }}
min_score: "70"
- name: Assert fixture outcome
shell: bash
run: |
if [ "${{ steps.scan.outcome }}" != "${{ matrix.expect_outcome }}" ]; then
echo "Expected fixture '${{ matrix.fixture }}' to '${{ matrix.expect_outcome }}', got '${{ steps.scan.outcome }}'."
exit 1
fi