mirror of
https://github.com/MadsLorentzen/ai-job-search.git
synced 2026-09-17 00:26:26 +00:00
fix(ci): skip the pristine-template guard in test_setup_command on forks (#463)
TemplatesStillCarryThePlaceholders asserts 05-cv-templates.md and 06-cover-letter-templates.md still carry their [FIRST_NAME]/[YOUR_*] tokens. /setup's documented Step 3.5/3.6 personalisation replaces exactly those tokens, so python-tests failed permanently on any personalized fork. Same @unittest.skipIf on GITHUB_REPOSITORY (defaulting to upstream when unset) as test_placeholder_integrity.py received in #407; that fix landed three days before this guard, which did not pick up the pattern. Co-authored-by: Nathan No-ot <244263078+Nnoot02@users.noreply.github.com>
This commit is contained in:
@@ -9,9 +9,12 @@ were not, so a full Path B/C run left `[YOUR_NAME]`, `[YOUR_EMAIL]` and
|
||||
on the drafter noticing. A real user (#420) ran `/setup` and then hand-edited both
|
||||
files to close the gap.
|
||||
"""
|
||||
import os
|
||||
import unittest
|
||||
from pathlib import Path
|
||||
|
||||
UPSTREAM = "MadsLorentzen/ai-job-search"
|
||||
|
||||
REPO = Path(__file__).resolve().parent.parent
|
||||
COMMAND = REPO / ".claude" / "commands" / "setup.md"
|
||||
SKILL_DIR = REPO / ".claude" / "skills" / "job-application-assistant"
|
||||
@@ -67,6 +70,10 @@ class SetupStep3ContactBlocks(unittest.TestCase):
|
||||
self.assertIn("06-cover-letter-templates.md", summary)
|
||||
|
||||
|
||||
@unittest.skipIf(
|
||||
os.environ.get("GITHUB_REPOSITORY", UPSTREAM) != UPSTREAM,
|
||||
"template-placeholder guard targets the pristine upstream template; forks personalize 05-cv-templates.md and 06-cover-letter-templates.md via /setup",
|
||||
)
|
||||
class TemplatesStillCarryThePlaceholders(unittest.TestCase):
|
||||
"""The instructions above target real tokens; if a template renames them,
|
||||
the instruction and this test must move together."""
|
||||
|
||||
Reference in New Issue
Block a user