Skip to content

[MDS-6179] Refactored ProjectOverviewTab.js to a functional Typescript Component #754

[MDS-6179] Refactored ProjectOverviewTab.js to a functional Typescript Component

[MDS-6179] Refactored ProjectOverviewTab.js to a functional Typescript Component #754

name: Common Package - Unit Tests
on:
pull_request:
paths:
- services/common/**
workflow_dispatch:
push:
branches:
- develop
paths:
- services/common/**
jobs:
test-common-package:
name: test-common-package
runs-on: ubuntu-20.04
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
steps:
- uses: actions/checkout@v3
name: checkout
- uses: actions/cache@v3
name: Cache yarn
with:
path: ./.yarn/cache
key: common-package
restore-keys: common-package
- uses: actions/setup-node@v2
with:
node-version: 18.x
- name: Upgrade yarn
run: npm install -g yarn
- name: Set Fontawesome token
run: |
yarn config set 'npmScopes["fortawesome"].npmAuthIdent' "${{ secrets.ARTIFACTORY_TOKEN }}"
yarn config set 'npmScopes["fortawesome"].npmAlwaysAuth' true
yarn config set 'npmScopes["fortawesome"].npmRegistryServer' "https://artifacts.developer.gov.bc.ca/artifactory/api/npm/m4c2-mds/"
- name: Install Dependencies
run: yarn install
- name: Run frontend tests
run: yarn workspace @mds/common run ci-test
- name: Upload test coverage results
uses: actions/upload-artifact@v4
if: success()
with:
name: common-test-results
path: |
services/common/coverage
services/common/reports/test-reporter.xml
- name: Sonar Reporting
uses: SonarSource/[email protected]
with:
projectBaseDir: services/common