Skip to content

feat: Implement FHIRPath projection functions #5000

feat: Implement FHIRPath projection functions

feat: Implement FHIRPath projection functions #5000

Workflow file for this run

# This workflow will build the software to ensure there are no errors, and also execute the tests.
name: Test
on:
pull_request:
jobs:
detect-changes:
name: Detect changes
runs-on: ubuntu-latest
# Skip pull requests from release branches (handled by pre-release workflow).
if: "!startsWith(github.head_ref, 'release/')"
outputs:
core: ${{ steps.filter.outputs.core }}
ui: ${{ steps.filter.outputs.ui }}
server: ${{ steps.filter.outputs.server }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Detect changed paths
uses: dorny/paths-filter@v3
id: filter
with:
filters: |
core:
- 'pom.xml'
- 'utilities/**'
- 'encoders/**'
- 'terminology/**'
- 'fhirpath/**'
- 'library-api/**'
- 'library-runtime/**'
- 'lib/python/**'
- 'lib/R/**'
- 'config/**'
- 'sql-on-fhir'
ui:
- 'ui/**'
server:
- 'server/**'
build-and-test:
name: Build and test
runs-on: ubuntu-latest
needs: detect-changes
if: needs.detect-changes.outputs.core == 'true'
permissions:
contents: read
outputs:
pathling-version: ${{ steps.get-version.outputs.version }}
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: recursive
- name: Set up build environment
uses: ./.github/actions/setup-build-tools
with:
java: "true"
r: "true"
python: "true"
spark: "true"
sonar-cache: "true"
- name: Get project version
id: get-version
run: |
VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "Pathling version: $VERSION"
- name: Run install goal
env:
R_KEEP_PKG_SOURCE: yes
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
mvn --batch-mode install \
org.sonarsource.scanner.maven:sonar-maven-plugin:sonar \
-Dsonar.projectKey=aehrc_pathling -Dsonar.organization=aehrc \
-Dsonar.host.url=https://sonarcloud.io \
-pl '!site,!benchmark'
timeout-minutes: 60
- name: Upload test artifacts
if: always()
uses: ./.github/actions/upload-test-artifacts
with:
include-jars: "true"
include-python: "true"
include-r: "true"
test-ui:
name: Test UI
needs: detect-changes
if: needs.detect-changes.outputs.ui == 'true'
uses: ./.github/workflows/ui-test.yml
test-server:
name: Test server
needs: [detect-changes, build-and-test]
if: |
always() &&
needs.detect-changes.outputs.server == 'true' &&
needs.detect-changes.result == 'success' &&
(needs.build-and-test.result == 'success' || needs.build-and-test.result == 'skipped')
uses: ./.github/workflows/server-test.yml
secrets: inherit
with:
download-library-jars: ${{ needs.detect-changes.outputs.core == 'true' }}
pathling-version: ${{ needs.build-and-test.outputs.pathling-version }}