diff --git a/.github/workflows/pr-checks.yml b/.github/workflows/pr-checks.yml index 5d2b1576f7..ba6dfbcdb8 100644 --- a/.github/workflows/pr-checks.yml +++ b/.github/workflows/pr-checks.yml @@ -126,10 +126,10 @@ jobs: if: ${{ !cancelled() && steps.install-deps.outcome == 'success' }} run: .github/workflows/script/verify-pr-checks.sh - - name: Run pr-checks tests + - name: Run pr-checks checks if: ${{ !cancelled() && steps.install-deps.outcome == 'success' }} working-directory: pr-checks - run: npx tsx --test + run: npm run checks - name: Run `pr-checks/changenotes.ts` to ensure that all unreleased change notes are valid if: ${{ !cancelled() && steps.install-deps.outcome == 'success' }} diff --git a/package.json b/package.json index 76ac14cf2d..31607ff78a 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,8 @@ "test": "npm run ava -- src/", "test-debug": "npm run test -- --timeout=20m", "transpile": "tsc --build --verbose tsconfig.json", - "update-pr-checks": "./pr-checks/sync.sh" + "update-pr-checks": "./pr-checks/sync.sh", + "typecheck": "tsc --noEmit" }, "license": "MIT", "workspaces": [ diff --git a/pr-checks/package.json b/pr-checks/package.json index 343f943814..f96b919c15 100644 --- a/pr-checks/package.json +++ b/pr-checks/package.json @@ -2,6 +2,11 @@ "private": true, "description": "Dependencies for codeql-action scripts", "type": "module", + "scripts": { + "typecheck": "tsc --noEmit", + "test": "npx tsx --test", + "checks": "npm run typecheck && npm run test" + }, "dependencies": { "@actions/core": "^2.0.3", "@actions/github": "^8.0.1", diff --git a/pr-checks/tsconfig.json b/pr-checks/tsconfig.json index e0a6c856c9..367148ab9a 100644 --- a/pr-checks/tsconfig.json +++ b/pr-checks/tsconfig.json @@ -9,5 +9,5 @@ "noEmit": true }, "include": ["./**/*.ts", "../src/**/*.ts"], - "exclude": ["node_modules"] + "exclude": ["node_modules", "../src/**/*.test.ts"] }