diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ec18d7d3..84bce57c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -66,7 +66,15 @@ jobs: ${{ runner.OS }}-node- ${{ runner.OS }}- - run: npm ci --legacy-peer-deps + - name: Configure Datadog Test Visibility + uses: datadog/test-visibility-github-action@v1 + with: + languages: js + service: gogovsg + api_key: ${{ secrets.DD_API_KEY }} - run: npm run test + env: + NODE_OPTIONS: -r ${{ env.DD_TRACE_PACKAGE }} --import ${{ env.DD_TRACE_ESM_IMPORT }} - name: Coveralls uses: coverallsapp/github-action@master with: @@ -91,7 +99,15 @@ jobs: ${{ runner.OS }}- - run: npm ci --legacy-peer-deps - run: echo CLOUDMERSIVE_KEY=${{secrets.CLOUDMERSIVE_KEY}} >> .env + - name: Configure Datadog Test Visibility + uses: datadog/test-visibility-github-action@v1 + with: + languages: js + service: gogovsg + api_key: ${{ secrets.DD_API_KEY }} - run: npm run test:e2e-headless + env: + NODE_OPTIONS: -r ${{ env.DD_TRACE_PACKAGE }} --import ${{ env.DD_TRACE_ESM_IMPORT }} integration: name: Integration Tests runs-on: ubuntu-22.04 @@ -113,7 +129,15 @@ jobs: - run: npm ci --legacy-peer-deps - run: npm run dev & - run: sleep 270 + - name: Configure Datadog Test Visibility + uses: datadog/test-visibility-github-action@v1 + with: + languages: js + service: gogovsg + api_key: ${{ secrets.DD_API_KEY }} - run: npm run test:integration + env: + NODE_OPTIONS: -r ${{ env.DD_TRACE_PACKAGE }} --import ${{ env.DD_TRACE_ESM_IMPORT }} gatekeep: name: Determine if Build & Deploy is needed outputs: