Skip to content

Commit 352dc65

Browse files
author
e
committed
ci: keep audit helper within workflow assets
1 parent f581f3d commit 352dc65

4 files changed

Lines changed: 4 additions & 4 deletions

File tree

File renamed without changes.

.github/workflows/security-audit.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
with:
4242
node-version: '22'
4343
- name: Audit ${{ matrix.lockfile }}
44-
run: node scripts/audit-production-dependencies.mjs --workspace "${{ matrix.path }}" --lockfile "${{ matrix.lockfile }}"
44+
run: node .github/scripts/audit-production-dependencies.mjs --workspace "${{ matrix.path }}" --lockfile "${{ matrix.lockfile }}"
4545

4646
security-audit:
4747
name: security-audit

tests/ci-workflow-coverage.test.mts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ const packageJson = JSON.parse(readFileSync(resolve(root, 'package.json'), 'utf8
1212
const packageScripts = packageJson.scripts ?? {};
1313
const deployGateWorkflow = readFileSync(resolve(workflowsDir, 'deploy-gate.yml'), 'utf8');
1414
const securityAuditWorkflow = readFileSync(resolve(workflowsDir, 'security-audit.yml'), 'utf8');
15-
const securityAuditScript = readFileSync(resolve(root, 'scripts/audit-production-dependencies.mjs'), 'utf8');
15+
const securityAuditScript = readFileSync(resolve(root, '.github/scripts/audit-production-dependencies.mjs'), 'utf8');
1616
const testWorkflow = readFileSync(resolve(workflowsDir, 'test.yml'), 'utf8');
1717
const workflowText = readdirSync(workflowsDir)
1818
.filter((name) => name.endsWith('.yml') || name.endsWith('.yaml'))
@@ -179,7 +179,7 @@ describe('CI workflow coverage', () => {
179179
assert.match(securityAuditWorkflow, /\n name: security-audit\n/, 'security-audit.yml must publish a security-audit check run');
180180
assert.match(
181181
securityAuditWorkflow,
182-
/node scripts\/audit-production-dependencies\.mjs/,
182+
/node \.github\/scripts\/audit-production-dependencies\.mjs/,
183183
'security-audit.yml must run the production dependency audit gate',
184184
);
185185
assert.match(

tests/security-audit-baseline.test.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import {
55
BASELINE_ADVISORIES_BY_LOCKFILE,
66
collectAuditFindings,
77
collectUnbaselinedFindings,
8-
} from '../scripts/audit-production-dependencies.mjs';
8+
} from '../.github/scripts/audit-production-dependencies.mjs';
99

1010
function auditReportWith(via) {
1111
return {

0 commit comments

Comments
 (0)