diff --git a/.github/workflows/code-health-tools.yml b/.github/workflows/code-health-tools.yml index d8ce90377c..b2a7249be7 100644 --- a/.github/workflows/code-health-tools.yml +++ b/.github/workflows/code-health-tools.yml @@ -46,6 +46,25 @@ jobs: - name: Run unit tests working-directory: tools/cli run: make unit-test + js-tests: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 + with: + sparse-checkout: | + .github + tools/spectral/ipa + - name: Setup Node + uses: actions/setup-node@v4 + with: + node-version: '20.x' + cache: 'npm' + - name: Install npm dependencies + run: npm install + - name: Run Jest tests + run: | + npm run test lint: runs-on: ubuntu-latest steps: diff --git a/.github/workflows/spectral-lint.yml b/.github/workflows/spectral-lint.yml index ad84f46374..e7b5b3faeb 100644 --- a/.github/workflows/spectral-lint.yml +++ b/.github/workflows/spectral-lint.yml @@ -7,6 +7,7 @@ on: - 'tools/spectral/**' - 'openapi/**.yaml' - '.spectral.yaml' + - 'ipa-spectral.yaml' push: branches: - main @@ -14,6 +15,7 @@ on: - 'tools/spectral/**' - 'openapi/**.yaml' - '.spectral.yaml' + - 'ipa-spectral.yaml' jobs: spectral-lint: @@ -33,3 +35,8 @@ jobs: # Path to the OpenAPI spec files and openapi/v2.yaml file_glob: openapi/v2.yaml spectral_ruleset: tools/spectral/.spectral.yaml #If updated, need to update in MMS too. + - name: IPA validation action + uses: stoplightio/spectral-action@2ad0b9302e32a77c1caccf474a9b2191a8060d83 + with: + file_glob: openapi/v2.yaml + spectral_ruleset: tools/spectral/ipa/ipa-spectral.yaml