chore(devextreme): create the localization gulp task alternative based on nx #28336
Workflow file for this run
This file contains hidden or 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: Demos unit tests | |
| concurrency: | |
| group: wf-${{github.event.pull_request.number || github.sha}}-${{github.workflow}} | |
| cancel-in-progress: true | |
| on: | |
| pull_request: | |
| paths-ignore: | |
| - 'apps/**/*.md' | |
| push: | |
| branches: [26_1] | |
| workflow_dispatch: | |
| env: | |
| RUN_TESTS: true | |
| jobs: | |
| check-should-run: | |
| name: Check if tests should run | |
| runs-on: devextreme-shr2 | |
| outputs: | |
| should-run: ${{ steps.check.outputs.should-run }} | |
| steps: | |
| - name: Check RUN_TESTS flag | |
| id: check | |
| run: echo "should-run=${{ env.RUN_TESTS }}" >> $GITHUB_OUTPUT | |
| test: | |
| name: Run unit tests | |
| needs: check-should-run | |
| if: needs.check-should-run.outputs.should-run == 'true' | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 60 | |
| steps: | |
| - name: Get sources | |
| uses: actions/checkout@v4 | |
| - name: Use Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - uses: pnpm/action-setup@v4 | |
| with: | |
| run_install: false | |
| - name: Get pnpm store directory | |
| shell: bash | |
| run: | | |
| echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV | |
| - uses: actions/cache@v4 | |
| name: Setup pnpm cache | |
| with: | |
| path: | | |
| ${{ env.STORE_PATH }} | |
| .nx/cache | |
| key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | |
| restore-keys: | | |
| ${{ runner.os }}-pnpm-store | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Run unit tests | |
| working-directory: apps/demos | |
| run: pnpx nx test |