-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (32 loc) · 1.14 KB
/
pull-request.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
name: PR Validation
run-name: PR Validation executed by @${{ github.actor }}
on: pull_request
jobs:
CHECK-UnitTest:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
- name: Setup Gradle
uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5
- run: ./gradlew elog:testDebugUnitTest
- name: Comment on failure
if: steps.job.status == 'failure'
uses: octokit/action-comment@v1
with:
repo: ${{ github.repository }}
issue_number: ${{ github.event.issue.number }}
body: "Verifique os testes unitarios"
- uses: actions/checkout@v2
- uses: octokit/action-get-job-status@v1 # Get job status
id: get-job-status
- name: Comment on success
if: steps.get-job-status.outputs.status != 'failure'
uses: octokit/action-comment@v1
with:
repo: ${{ github.repository }}
issue_number: ${{ github.event.issue.number }}
body: "Todos os testes passaram com sucesso =)"