|
| 1 | +name: daily-gsifi-governance-validation |
| 2 | + |
| 3 | +on: |
| 4 | + workflow_dispatch: |
| 5 | + |
| 6 | + pull_request: |
| 7 | + paths: |
| 8 | + - 'DAILY_GSIFI_AGI_ASI_GOVERNANCE_2026_2030.md' |
| 9 | + - 'artifacts/daily_governance_report.example.json' |
| 10 | + - 'artifacts/daily_governance_report.schema.json' |
| 11 | + - 'policies/sentinel_governance.rego' |
| 12 | + - 'test_governance_snippets.py' |
| 13 | + - 'GOVERNANCE_ARTIFACTS_README.md' |
| 14 | + - 'Makefile' |
| 15 | + - 'tools/generate_gsifi_governance_report.py' |
| 16 | + - 'tools/run_gsifi_governance_checks.py' |
| 17 | + - 'test_run_gsifi_governance_checks.py' |
| 18 | + - 'test_daily_gsifi_governance_workflow.py' |
| 19 | + - 'test_generate_gsifi_governance_report.py' |
| 20 | + - 'test_validate_governance_artifacts.py' |
| 21 | + - 'tools/validate_governance_artifacts.py' |
| 22 | + - '.github/workflows/daily-gsifi-governance-validation.yml' |
| 23 | + - 'requirements-governance-checks.txt' |
| 24 | + push: |
| 25 | + branches: [main, master] |
| 26 | + paths: |
| 27 | + - 'DAILY_GSIFI_AGI_ASI_GOVERNANCE_2026_2030.md' |
| 28 | + - 'artifacts/daily_governance_report.example.json' |
| 29 | + - 'artifacts/daily_governance_report.schema.json' |
| 30 | + - 'policies/sentinel_governance.rego' |
| 31 | + - 'test_governance_snippets.py' |
| 32 | + - 'GOVERNANCE_ARTIFACTS_README.md' |
| 33 | + - 'Makefile' |
| 34 | + - 'tools/generate_gsifi_governance_report.py' |
| 35 | + - 'tools/run_gsifi_governance_checks.py' |
| 36 | + - 'test_run_gsifi_governance_checks.py' |
| 37 | + - 'test_daily_gsifi_governance_workflow.py' |
| 38 | + - 'test_generate_gsifi_governance_report.py' |
| 39 | + - 'test_validate_governance_artifacts.py' |
| 40 | + - 'tools/validate_governance_artifacts.py' |
| 41 | + - '.github/workflows/daily-gsifi-governance-validation.yml' |
| 42 | + - 'requirements-governance-checks.txt' |
| 43 | + |
| 44 | +permissions: |
| 45 | + contents: read |
| 46 | + |
| 47 | +jobs: |
| 48 | + validate: |
| 49 | + runs-on: ubuntu-latest |
| 50 | + timeout-minutes: 10 |
| 51 | + steps: |
| 52 | + - name: Checkout |
| 53 | + uses: actions/checkout@v4 |
| 54 | + |
| 55 | + - name: Setup Python |
| 56 | + uses: actions/setup-python@v5 |
| 57 | + with: |
| 58 | + python-version: '3.12' |
| 59 | + |
| 60 | + - name: Install test dependencies |
| 61 | + run: | |
| 62 | + python -m pip install --upgrade pip |
| 63 | + pip install -r requirements-governance-checks.txt |
| 64 | +
|
| 65 | + - name: Run Python syntax checks |
| 66 | + run: make daily-gsifi-governance-pycompile |
| 67 | + |
| 68 | + - name: Run governance checks with JUnit output |
| 69 | + run: make daily-gsifi-governance-ci |
| 70 | + |
| 71 | + - name: Generate governance markdown summary |
| 72 | + run: make daily-gsifi-governance-report |
| 73 | + |
| 74 | + - name: Append governance summary to job summary |
| 75 | + if: always() |
| 76 | + run: cat artifacts/test-results/gsifi-governance-run-summary.md >> "$GITHUB_STEP_SUMMARY" |
| 77 | + |
| 78 | + - name: Upload governance test report |
| 79 | + if: always() |
| 80 | + uses: actions/upload-artifact@v4 |
| 81 | + with: |
| 82 | + name: gsifi-governance-test-report |
| 83 | + path: | |
| 84 | + artifacts/test-results/gsifi-governance-tests.xml |
| 85 | + artifacts/test-results/gsifi-governance-run-summary.json |
| 86 | + artifacts/test-results/gsifi-governance-run-summary.md |
0 commit comments