Skip to content

test: adj validator #183

test: adj validator

test: adj validator #183

Workflow file for this run

name: ADJ Validator
on:
push:
pull_request:
jobs:
validate-adj:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.13"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install jsonschema
- name: Run ADJ validation
id: adj_validation
run: |
set +e
python3 .github/workflows/scripts/adj-tester/main.py 2> error.log
EXIT_CODE=$?
echo "exit_code=$EXIT_CODE" >> $GITHUB_OUTPUT
exit $EXIT_CODE
- name: Send Slack notification if failed
if: failure()
run: |
ERROR_MESSAGE=$(cat error.log)
curl -X POST -H 'Content-type: application/json' \
--data "{
\"text\": \"❌ *ADJ Validator Failed* \n
Repository: ${{ github.repository }} \n
Branch: ${{ github.ref_name }} \n
Actor: ${{ github.actor }} \n
Commit: ${{ github.sha }} \n
Error:\n\`\`\`$ERROR_MESSAGE\`\`\`\"
}" \
${{ secrets.SLACK_WEBHOOK_URL }}