Skip to content

Commit 1ab99f9

Browse files
Create allure-report.yml
1 parent 1a0bae8 commit 1ab99f9

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/workflows/allure-report.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Run tests and publish report
2+
on: [push, workflow_dispatch]
3+
jobs:
4+
test:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- uses: actions/checkout@v3
8+
9+
- name: Set up JDK
10+
uses: actions/setup-java@v3
11+
with:
12+
distribution: zulu
13+
java-version: 17
14+
15+
- name: Run tests
16+
run: ./gradlew clean test
17+
18+
- name: Load test report history
19+
uses: actions/checkout@v3
20+
if: always()
21+
continue-on-error: true
22+
with:
23+
ref: gh-pages
24+
path: gh-pages
25+
26+
- name: Build test report
27+
uses: simple-elf/allure-report-action@v1.7
28+
if: always()
29+
with:
30+
gh_pages: gh-pages
31+
allure_history: allure-history
32+
allure_results: build/allure-results
33+
34+
- name: Publish test report
35+
uses: peaceiris/actions-gh-pages@v3
36+
if: always()
37+
with:
38+
github_token: ${{ secrets.GITHUB_TOKEN }}
39+
publish_branch: gh-pages
40+
publish_dir: allure-history

0 commit comments

Comments
 (0)