This repository has been archived by the owner on Dec 17, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
49 lines (42 loc) · 1.69 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
39
40
41
42
43
44
45
46
47
48
49
name: Pull-request checks
on:
pull_request:
branches:
- main
paths:
- igs/MessagingCore/**
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
env:
IG: MessagingCore
steps:
- uses: actions/checkout@v2
# Persist the FHIR Package Cache between runners.
# Doc: https://confluence.hl7.org/display/FHIR/FHIR+Package+Cache
- name: 🗂️ Cache FHIR Packages
uses: actions/cache@v2
with:
path: |
~/.fhir/packages
key: fhir-packages
# Builds the .fsh files into FHIR .json resources.
# Doc: https://fshschool.org/docs/sushi/running
- name: 🍣 Run SUSHI
run: |
npm install -g fsh-sushi
sushi igs/${{ env.IG }}
- name: 📥 Download test tools
run: |
wget -q https://github.com/navikt/fhir-validator-junit-engine/releases/latest/download/fhir-validator-junit-engine.jar
wget -q https://github.com/hapifhir/org.hl7.fhir.core/releases/latest/download/validator_cli.jar
wget -q https://repo1.maven.org/maven2/org/junit/platform/junit-platform-console-standalone/1.8.1/junit-platform-console-standalone-1.8.1.jar
- name: ✔️ Run tests
run: java -jar junit-platform-console-standalone-1.8.1.jar -cp fhir-validator-junit-engine.jar:validator_cli.jar -f igs/${{ env.IG }}/test/*.yaml --reports-dir test-results
- name: 📤 Publish results (unit test)
if: github.actor != 'dependabot[bot]' # requires write permission
uses: EnricoMi/publish-unit-test-result-action@v1
with:
commit: ${{ github.event.workflow_run.head_sha }}
files: "test-results/TEST-*.xml"