Skip to content

Commit a500dbe

Browse files
author
bowenislandsong
committed
Add flake analyzer
This commit introduces the flake analyzer to OLM to create weekly flake reports for the past and previous 7 days. The result will be uploaded to GITHUB as artifacts. It also allows commenting test reports on open PRs trigged by their failed upstream e2e test.
1 parent cf8d964 commit a500dbe

File tree

2 files changed

+23
-1
lines changed

2 files changed

+23
-1
lines changed

.github/workflows/e2e-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
steps:
1111
- uses: actions/checkout@v2
1212
- run: make -f x.mk e2e-local NODES=2 JUNIT_DIRECTORY=./artifacts/
13-
- name: Archive production artifacts # test results are only uploaded if any of the e2e tests fails
13+
- name: Archive Test Artifacts # test results are only uploaded if any of the e2e tests fails
1414
if: ${{ failure() }}
1515
uses: actions/upload-artifact@v2
1616
with:
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: flake-analyzer-periodics
2+
on:
3+
schedule:
4+
- cron: '0 1 * * *'
5+
jobs:
6+
generate-flake-analysis-report:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: Periodic Flake Report
10+
env:
11+
FLAKE_BOT_SECRET: ${{ secrets.GITHUB_TOKEN }}
12+
run: |
13+
git clone -b v0.1.1 https://github.com/operator-framework/flake-analyzer.git
14+
cd ./flake-analyzer
15+
make report-today OWNER=operator-framework REPO=operator-lifecycle-manager TOKEN=$FLAKE_BOT_SECRET TEST_SUITE=e2e-test-output OUTPUT_FILE=./report/artifacts/flake-report-today-$(date +"%m-%d-%Y").yaml
16+
make report-last-7-days OWNER=operator-framework REPO=operator-lifecycle-manager TOKEN=$FLAKE_BOT_SECRET TEST_SUITE=e2e-test-output OUTPUT_FILE=./report/artifacts/flake-report-last-7-days-$(date +"%m-%d-%Y").yaml
17+
make report-prev-7-days OWNER=operator-framework REPO=operator-lifecycle-manager TOKEN=$FLAKE_BOT_SECRET TEST_SUITE=e2e-test-output OUTPUT_FILE=./report/artifacts/flake-report-prev-7-days-$(date +"%m-%d-%Y").yaml
18+
- name: Archive Reoport artifacts # test results are only uploaded if any of the e2e tests fails
19+
uses: actions/upload-artifact@v2
20+
with:
21+
name: flake-report-${{ github.run_id }}
22+
path: ${{ github.workspace }}/flake-analyzer/report/artifacts/*

0 commit comments

Comments
 (0)