Skip to content

Merge pull request #85 from lidofinance/feature/emergency-protected-t… #34

Merge pull request #85 from lidofinance/feature/emergency-protected-t…

Merge pull request #85 from lidofinance/feature/emergency-protected-t… #34

Workflow file for this run

---
name: "Test Proofs"
on:
push:
branches:
- develop
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Run Proofs in KaaS
run: |
sha=$(git rev-parse HEAD)
branch_name=$(git rev-parse --abbrev-ref HEAD)
response=$(curl -X POST \
-w "%{http_code}" \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${{ secrets.RV_COMPUTE_TOKEN }}" \
https://api.github.com/repos/runtimeverification/_kaas_lidofinance_dual-governance/actions/workflows/lido-ci.yml/dispatches \
-d '{
"ref": "develop",
"inputs": {
"branch_name": "'"${{ github.event.pull_request.head.sha || github.sha }}"'",
"extra_args": "script",
"statuses_sha": "'$sha'",
"org": "${{ github.repository_owner }}",
"repository": "${{ github.event.repository.name }}",
"auth_token": "'"${{ secrets.LIDO_STATUS_TOKEN }}"'"
}
}')
if [ "$response" -ge 200 ] && [ "$response" -lt 300 ]; then
echo "The request was successful"
elif [ "$response" -ge 400 ] && [ "$response" -lt 500 ]; then
echo "There was a client error: $response"
exit 1
else
echo "There was a server error: $response"
exit 1
fi