-
Notifications
You must be signed in to change notification settings - Fork 189
52 lines (42 loc) · 1.45 KB
/
ScreenShotTest.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: ScreenShotTest
on:
pull_request:
jobs:
screenshot-test:
runs-on: macos-12
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Validate Gradle Wrapper
uses: gradle/[email protected]
- name: Copy CI gradle.properties
run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 11
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
- name: Download Screenshots
id: download-artifact
uses: dawidd6/action-download-artifact@v2
with:
workflow: UpdateScreenshots.yml
name: screenshots
path: preview-screenshots/src/test/snapshots/images
- name: Run screenshot tests
id: verifyPaparazziDebug
continue-on-error: true
run: ./gradlew preview-screenshots:verifyPaparazziDebug
- name: Save PR number
run: |
mkdir -p ./preview-screenshots/out/failures
echo ${{ github.event.number }} > ./preview-screenshots/out/failures/NR
- name: Error Screenshot tests
if: ${{ hashFiles('preview-screenshots/out/failures/*.png') != '' }}
uses: actions/upload-artifact@v3
with:
name: screenshot-test-results
path: preview-screenshots/out/failures