feat: Add import
option
#1396
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: Test | |
on: | |
push: | |
pull_request: | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install-deps | |
- name: Check duplication in lockfile | |
run: pnpm dedupe --check | |
- uses: ./.github/actions/build-packages | |
- name: Lint files | |
run: pnpm run lint | |
- name: Type check | |
run: pnpm run type-check | |
test: | |
runs-on: ${{ matrix.os }} | |
needs: | |
- lint | |
strategy: | |
matrix: | |
node-version: [18.x, 20.x, 21.x] | |
os: [ubuntu-latest, windows-latest] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install-deps | |
with: | |
node-version: ${{ matrix.node-version }} | |
- uses: ./.github/actions/build-packages | |
# https://github.com/actions/virtual-environments/issues/712#issuecomment-613004302 | |
- name: Set TEMP on Windows | |
run: echo "TEMP=$env:USERPROFILE\AppData\Local\Temp" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
if: ${{ runner.os == 'Windows' }} | |
- uses: azure/setup-kubectl@v3 | |
with: | |
version: v1.23.1 | |
- uses: azure/setup-helm@v3 | |
with: | |
version: 3.10.2 | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- uses: ./.github/actions/setup-kustomize | |
- name: Run unit tests | |
run: pnpm run test:unit --coverage | |
- name: Run integration tests | |
run: pnpm run test:integration | |
- uses: codecov/codecov-action@v4 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
test-browser: | |
runs-on: ubuntu-latest | |
needs: | |
- lint | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/install-deps | |
- name: Install Chrome | |
run: pnpm puppeteer browsers install chrome | |
- uses: ./.github/actions/build-packages | |
- name: Run browser tests | |
run: pnpm run test:browser |