Make OpenAiAiAssertionModel httpClient customizable and add timeout setting #1449
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CompareScreenshot | |
on: | |
pull_request: | |
permissions: {} | |
jobs: | |
compare-screenshot-test: | |
runs-on: macos-latest | |
timeout-minutes: 20 | |
permissions: | |
contents: read # for clone | |
actions: write # for upload-artifact | |
checks: read # for wait-on-check-action | |
steps: | |
- name: Checkout base branch | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | |
with: | |
ref: ${{ github.base_ref }} | |
- name: Set up JDK 17 | |
uses: actions/setup-java@0ab4596768b603586c0de567f2430c30f5b0d2b0 # v3.13.0 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Setup Gradle | |
uses: gradle/gradle-build-action@a8f75513eafdebd8141bd1cd4e30fcd194af8dfa # v2.12.0 | |
with: | |
gradle-version: wrapper | |
- name: Get base branch HEAD commit | |
id: get_base_branch_head | |
run: echo "sha=$(git rev-parse origin/${{ github.base_ref }})" >> "$GITHUB_OUTPUT" | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 | |
- name: Wait for base unit-test to succeed before downloading base branch screenshot artifact | |
uses: lewagon/wait-on-check-action@ccfb013c15c8afb7bf2b7c028fb74dc5a068cccc # v1.3.4 | |
with: | |
ref: ${{ steps.get_base_branch_head.outputs.sha }} | |
check-name: 'store-screenshot-test' | |
repo-token: ${{ github.token }} | |
wait-interval: 10 | |
- uses: dawidd6/action-download-artifact@268677152d06ba59fcec7a7f0b5d961b6ccd7e1e # v2 | |
continue-on-error: true | |
with: | |
name: screenshot | |
workflow: StoreScreenshot.yml | |
commit: ${{ steps.get_base_branch_head.outputs.sha }} | |
if_no_artifact_found: fail | |
- name: compare screenshot test | |
id: compare-screenshot-test | |
run: | | |
./gradlew compareRoborazziDebug compareRoborazziDesktop compareRoborazziJvm compareRoborazziIosArm64 compareRoborazziIosX64 --stacktrace --info | |
- uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4 | |
if: ${{ always() }} | |
with: | |
name: screenshot-diff | |
path: | | |
**/build/outputs/roborazzi | |
retention-days: 30 | |
- uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4 | |
if: ${{ always() }} | |
with: | |
name: screenshot-diff-reports | |
path: | | |
**/build/reports | |
**/build/outputs/roborazzi | |
retention-days: 30 | |
- uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4 | |
if: ${{ always() }} | |
with: | |
name: screenshot-diff-test-results | |
path: | | |
**/build/test-results | |
retention-days: 30 | |
- name: Save PR number | |
if: ${{ github.event_name == 'pull_request' }} | |
run: | | |
mkdir -p ./pr | |
echo ${{ github.event.number }} > ./pr/NR | |
- uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4 | |
with: | |
name: pr | |
path: pr/ |