Adding current mbi join for matching counts #217
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: Run unit and integration tests | |
on: | |
pull_request: | |
workflow_dispatch: # Allow manual trigger | |
jobs: | |
test: | |
runs-on: self-hosted | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@v3 | |
- name: Setup Java | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '17' | |
distribution: temurin | |
cache: maven | |
- name: Set env vars from AWS params | |
uses: cmsgov/ab2d-bcda-dpc-platform/actions/aws-params-env-action@main | |
env: | |
AWS_REGION: ${{ vars.AWS_REGION }} | |
with: | |
params: | | |
ARTIFACTORY_URL=/artifactory/url | |
ARTIFACTORY_USER=/artifactory/user | |
ARTIFACTORY_PASSWORD=/artifactory/password | |
SONAR_HOST_URL=/sonarqube/url | |
SONAR_TOKEN=/sonarqube/token | |
- name: Assume role in AB2D dev account | |
uses: aws-actions/configure-aws-credentials@v3 | |
with: | |
aws-region: ${{ vars.AWS_REGION }} | |
role-to-assume: ${{ vars.AB2D_DEV_ROLE }} | |
- name: Set env vars from AWS params | |
uses: cmsgov/ab2d-bcda-dpc-platform/actions/aws-params-env-action@main | |
with: | |
params: | | |
OKTA_CLIENT_ID=/okta/client-id | |
OKTA_CLIENT_PASSWORD=/okta/client-secret | |
SECONDARY_USER_OKTA_CLIENT_ID=/secondary-okta/client-id | |
SECONDARY_USER_OKTA_CLIENT_PASSWORD=/secondary-okta/client-secret | |
- name: Install Maven 3.6.3 | |
run: | | |
export PATH="$PATH:/opt/maven/bin" | |
echo "PATH=$PATH" >> $GITHUB_ENV | |
if mvn -v; then echo "Maven already installed" && exit 0; else echo "Installing Maven"; fi | |
tmpdir="$(mktemp -d)" | |
curl -LsS https://archive.apache.org/dist/maven/maven-3/3.6.3/binaries/apache-maven-3.6.3-bin.tar.gz | tar xzf - -C "$tmpdir" | |
sudo rm -rf /opt/maven | |
sudo mv "$tmpdir/apache-maven-3.6.3" /opt/maven | |
- name: Clean maven | |
run: | | |
mvn -ntp -U clean | |
- name: SonarQube analysis | |
run: | | |
mvn -ntp -s settings.xml ${RUNNER_DEBUG:+"--debug"} compile sonar:sonar -Dsonar.projectKey=ab2d-project -Dsonar.qualitygate.wait=true -DskipTests -Dusername=${ARTIFACTORY_USER} -Dpassword=${ARTIFACTORY_PASSWORD} -Drepository_url=${ARTIFACTORY_URL} | |
- name: Run unit and integration tests | |
run: | | |
mvn -ntp -s settings.xml ${RUNNER_DEBUG:+"--debug"} -Dusername=${ARTIFACTORY_USER} -Dpassword=${ARTIFACTORY_PASSWORD} -Drepository_url=${ARTIFACTORY_URL} test -pl common,job,coverage,api,worker |