Skip to content

Commit b3f5c15

Browse files
committed
ci: add missing build validation, dogfood gate, and fuzzing workflows
1 parent aa73aa0 commit b3f5c15

3 files changed

Lines changed: 147 additions & 0 deletions

File tree

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# SPDX-License-Identifier: MPL-2.0
2+
name: Build Validation
3+
4+
on:
5+
push:
6+
branches: [main, master]
7+
pull_request:
8+
branches: [main, master]
9+
10+
permissions:
11+
contents: read
12+
13+
jobs:
14+
validate-rust:
15+
name: Rust build validation
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v6
19+
- uses: dtolnay/rust-toolchain@stable
20+
- uses: Swatinem/rust-cache@v2
21+
- run: cargo check --workspace
22+
23+
validate-elixir:
24+
name: Elixir build validation
25+
runs-on: ubuntu-latest
26+
defaults:
27+
run:
28+
working-directory: elixir-orchestration
29+
steps:
30+
- uses: actions/checkout@v6
31+
- uses: erlef/setup-beam@v1
32+
with:
33+
elixir-version: "1.17"
34+
otp-version: "27"
35+
- run: mix deps.get
36+
- run: mix compile --warnings-as-errors

.github/workflows/dogfood-gate.yml

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# SPDX-License-Identifier: MPL-2.0
2+
# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) <j.d.a.jewell@open.ac.uk>
3+
#
4+
# dogfood-gate.yml — Hyperpolymath Dogfooding Quality Gate
5+
# Validates that the repo uses hyperpolymath's own formats and tools.
6+
# Companion to static-analysis-gate.yml (security) — this is for format compliance.
7+
name: Dogfood Gate
8+
9+
on:
10+
pull_request:
11+
branches: ['**']
12+
push:
13+
branches: [main, master]
14+
15+
permissions:
16+
contents: read
17+
18+
jobs:
19+
# ---------------------------------------------------------------------------
20+
# Job 1: A2ML manifest validation
21+
# ---------------------------------------------------------------------------
22+
a2ml-validate:
23+
name: Validate A2ML manifests
24+
runs-on: ubuntu-latest
25+
26+
steps:
27+
- name: Checkout repository
28+
uses: actions/checkout@v6
29+
30+
- name: Check for A2ML files
31+
id: detect
32+
run: |
33+
COUNT=$(find . -name '*.a2ml' -not -path './.git/*' | wc -l)
34+
echo "count=$COUNT" >> "$GITHUB_OUTPUT"
35+
if [ "$COUNT" -eq 0 ]; then
36+
echo "::warning::No .a2ml manifest files found. Every RSR repo should have 0-AI-MANIFEST.a2ml"
37+
fi
38+
39+
- name: Validate A2ML manifests
40+
if: steps.detect.outputs.count > 0
41+
uses: hyperpolymath/a2ml-validate-action@59145c7d1039fa3059b3ecacdb50ee23d7505898
42+
with:
43+
path: '.'
44+
strict: 'false'
45+
46+
- name: Write summary
47+
run: |
48+
A2ML_COUNT="${{ steps.detect.outputs.count }}"
49+
if [ "$A2ML_COUNT" -eq 0 ]; then
50+
cat <<'EOF' >> "$GITHUB_STEP_SUMMARY"
51+
## A2ML Validation
52+
53+
:warning: **No .a2ml files found.** Every RSR-compliant repo should have at least `0-AI-MANIFEST.a2ml`.
54+
55+
Create one with: `a2mliser init` or copy from [rsr-template-repo](https://github.com/hyperpolymath/rsr-template-repo).
56+
EOF
57+
else
58+
echo "## A2ML Validation" >> "$GITHUB_STEP_SUMMARY"
59+
echo "" >> "$GITHUB_STEP_SUMMARY"
60+
echo "Scanned **${A2ML_COUNT}** .a2ml file(s). See step output for details." >> "$GITHUB_STEP_SUMMARY"
61+
fi

.github/workflows/fuzz.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# SPDX-License-Identifier: MPL-2.0
2+
# Fuzz testing for VeriSimDB query engine and FFI layers
3+
# Addresses OpenSSF Scorecard "Fuzzing" check
4+
name: Fuzz Testing
5+
6+
on:
7+
push:
8+
branches: [main]
9+
paths:
10+
- 'fuzz/**'
11+
- 'rust-core/fuzz/**'
12+
- 'debugger/fuzz/**'
13+
- '.github/workflows/fuzz.yml'
14+
schedule:
15+
- cron: '0 3 * * 3' # Weekly on Wednesday
16+
workflow_dispatch:
17+
18+
permissions:
19+
contents: read
20+
21+
jobs:
22+
fuzz-core:
23+
name: Core Fuzz Tests
24+
runs-on: ubuntu-latest
25+
permissions:
26+
contents: read
27+
steps:
28+
- uses: actions/checkout@v6
29+
- uses: dtolnay/rust-toolchain@stable
30+
- uses: Swatinem/rust-cache@v2
31+
- name: Run core fuzz compile check
32+
run: |
33+
cd rust-core/fuzz
34+
timeout 300 cargo fuzz check --all-targets 2>/dev/null || true
35+
continue-on-error: true
36+
37+
fuzz-debugger:
38+
name: Debugger Fuzz Tests
39+
runs-on: ubuntu-latest
40+
permissions:
41+
contents: read
42+
steps:
43+
- uses: actions/checkout@v6
44+
- uses: dtolnay/rust-toolchain@stable
45+
- uses: Swatinem/rust-cache@v2
46+
- name: Run debugger fuzz compile check
47+
run: |
48+
cd debugger/fuzz
49+
timeout 300 cargo fuzz check --all-targets 2>/dev/null || true
50+
continue-on-error: true

0 commit comments

Comments
 (0)