From da79ee234f802ba4f11d4a7fc093463bf17d37f2 Mon Sep 17 00:00:00 2001 From: peptiderepo Date: Mon, 27 Apr 2026 15:37:34 +0000 Subject: [PATCH] fix(ci): explicitly checkout peptide-e2e in workflow_call context When smoke.yml runs via workflow_call from another repo (peptide-repo-core, peptide-starter-theme, etc.), GitHub Actions checks out the CALLER's repo by default. The caller has no package-lock.json, so setup-node's npm cache lookup fails with 'Some specified paths were not resolved'. Fix: add repository/ref to the checkout step so we always fetch peptide-e2e regardless of who calls the workflow. This ensures npm ci and Playwright have the correct test code and dependency lockfile. --- .github/workflows/smoke.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/smoke.yml b/.github/workflows/smoke.yml index 2c25c1a..dd56143 100755 --- a/.github/workflows/smoke.yml +++ b/.github/workflows/smoke.yml @@ -2,6 +2,10 @@ # # Called by other repos via workflow_call as a deploy gate. # Secrets required: STAGING_WP_ADMIN_USER, STAGING_WP_ADMIN_PASSWORD +# +# IMPORTANT: When called via workflow_call, GitHub Actions checks out the +# CALLER's repo by default, not peptide-e2e. We explicitly checkout +# peptide-e2e so npm ci and Playwright have the correct test code + lock file. name: Smoke Tests (Staging) @@ -32,8 +36,11 @@ jobs: timeout-minutes: 15 steps: - - name: Checkout + - name: Checkout peptide-e2e (explicit — workflow_call defaults to caller repo) uses: actions/checkout@v4 + with: + repository: peptiderepo/peptide-e2e + ref: main - name: Set up Node.js uses: actions/setup-node@v4