|
| 1 | +name: Verify |
| 2 | +on: |
| 3 | + workflow_call: |
| 4 | + inputs: |
| 5 | + version: |
| 6 | + required: true |
| 7 | + type: string |
| 8 | + staging: |
| 9 | + required: false |
| 10 | + default: false |
| 11 | + type: boolean |
| 12 | + secrets: |
| 13 | + repository-username: |
| 14 | + required: false |
| 15 | + repository-password: |
| 16 | + required: false |
| 17 | + google-chat-webhook-url: |
| 18 | + required: true |
| 19 | + token: |
| 20 | + required: true |
| 21 | +jobs: |
| 22 | + verify: |
| 23 | + name: Verify |
| 24 | + runs-on: ubuntu-latest |
| 25 | + steps: |
| 26 | + - name: Check Out Release Verification Tests |
| 27 | + uses: actions/checkout@v4 |
| 28 | + with: |
| 29 | + repository: spring-projects/spring-framework-release-verification |
| 30 | + ref: 'v0.0.2' |
| 31 | + token: ${{ secrets.token }} |
| 32 | + - name: Check Out Send Notification Action |
| 33 | + uses: actions/checkout@v4 |
| 34 | + with: |
| 35 | + path: spring-framework |
| 36 | + sparse-checkout: .github/actions/send-notification |
| 37 | + - name: Set Up Java |
| 38 | + uses: actions/setup-java@v4 |
| 39 | + with: |
| 40 | + distribution: 'liberica' |
| 41 | + java-version: 17 |
| 42 | + - name: Set Up Gradle |
| 43 | + uses: gradle/actions/setup-gradle@dbbdc275be76ac10734476cc723d82dfe7ec6eda # v3.4.2 |
| 44 | + with: |
| 45 | + cache-read-only: false |
| 46 | + - name: Configure Gradle Properties |
| 47 | + shell: bash |
| 48 | + run: | |
| 49 | + mkdir -p $HOME/.gradle |
| 50 | + echo 'org.gradle.daemon=false' >> $HOME/.gradle/gradle.properties |
| 51 | + - name: Run Release Verification Tests |
| 52 | + env: |
| 53 | + RVT_VERSION: ${{ inputs.version }} |
| 54 | + RVT_RELEASE_TYPE: oss |
| 55 | + RVT_STAGING: ${{ inputs.staging }} |
| 56 | + RVT_OSS_REPOSITORY_USERNAME: ${{ secrets.repository-username }} |
| 57 | + RVT_OSS_REPOSITORY_PASSWORD: ${{ secrets.repository-password }} |
| 58 | + run: ./gradlew spring-framework-release-verification-tests:test |
| 59 | + - name: Upload Build Reports on Failure |
| 60 | + uses: actions/upload-artifact@v4 |
| 61 | + if: failure() |
| 62 | + with: |
| 63 | + name: build-reports |
| 64 | + path: '**/build/reports/' |
| 65 | + - name: Send Notification |
| 66 | + uses: ./spring-framework/.github/actions/send-notification |
| 67 | + if: failure() |
| 68 | + with: |
| 69 | + webhook-url: ${{ secrets.google-chat-webhook-url }} |
| 70 | + status: ${{ job.status }} |
| 71 | + run-name: ${{ format('{0} | Verification | {1}', github.ref_name, inputs.version) }} |
0 commit comments