Skip to content

Deflake

Deflake #314

Workflow file for this run

name: Deflake
on:
schedule:
- cron: '0 12 * * *'
workflow_dispatch:
permissions:
contents: read
jobs:
deflake:
runs-on: ubuntu-latest
permissions:
contents: read
statuses: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1
with:
disable-telemetry: true
egress-policy: block
allowed-endpoints: >
api.github.com:443
github.com:443
objects.githubusercontent.com:443
proxy.golang.org:443
storage.googleapis.com:443
sum.golang.org:443
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: ./.github/actions/install-deps
- name: Running tests 5 times to find flaky tests
id: run-deflake
run: make deflake
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- if: always()
name: Post commit status
run: |
curl \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}"\
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/${{ github.repository }}/statuses/${{ github.sha }} \
-d '{"state":"${{ steps.run-deflake.outcome }}","target_url":"${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}","context":"Deflake Tests (cron)"}'