Skip to content

Partner block in the challenge schema - #113

Merged
wab merged 2 commits into
mainfrom
claude/challenge-partner-block-c3bf9c
Oct 22, 2026
Merged

wab merged 2 commits into
mainfrom
claude/challenge-partner-block-c3bf9c

Conversation

@wab

@wab wab commented Oct 22, 2026 •

Copy link
Copy Markdown
Collaborator

Closes #97

What

  • scripts/schemas/challenge.schema.js: optional partner block, strict, placed after workstreams as in the mockup. tool is a Tool slug, sentence ≤ 140, metrics exactly 2 of {before ≤ 12, after ≤ 12, label ≤ 90}, source required ≤ 90. No field names Qobra.
  • scripts/validate-repository.js: partner.tool must be an existing Tool slug. The error names the slug, at path partner.tool. Like team tools and featuredTool, the raw value is checked, so a padded slug is rejected.
  • scripts/__tests__/fixtures/challenges/sales-compensation.md: gains partner.tool: qobra with the sentence, metrics and source of enjeux-remuneration-variable.html (ocobo-revops/prototype, main).

Tests

  • Seam 1 (scripts/__tests__/challenge.schema.test.js): 1 and 3 metrics fail, each missing field fails (source included), each cap (both metrics) accepts its limit and fails one past it, blank tool and unknown keys fail, a challenge without partner passes, any challenge key may carry it.
  • Seam 2 (scripts/__tests__/validate-repository.test.js): partner.tool: ghost-tool fails with "ghost-tool" does not match any tool slug; a padded " qobra " fails too; the Sales Compensation fixture with tools/qobra.md passes. The fixture edit throws when it does not apply.
  • CLAUDE.md: partner.tool added to "Cross-refs are strict".
  • pnpm test 399 passed, pnpm validate green.

Choices to review

  • The mockup's editorial note [Bloc à valider avec Qobra] after the source is left out of source: it is a mockup reminder, not page copy.
  • The metric labels keep the mockup's (source : Qobra) suffix verbatim, although source already attributes the figures. Drop it when Qobra validates the block (assumption A2) if the page should not repeat the attribution.
  • after: "1" is quoted in YAML: an unquoted 1 is a number and fails the string schema.

Not in this PR

Adds partner (tool, sentence, two before/after metrics, required source) to
the challenge schema with its caps, checks partner.tool against Tool slugs
in validateRepository, and gives the Sales Compensation fixture the Qobra
block from the mockup.

Closes #97
@github-actions

github-actions Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

🔍 Preview: https://website-3j1nq9p6k-ocobo-22231b32.vercel.app

Built from website main with content from this PR's branch.

Applies the PR #113 review: the partner.tool cross-reference no longer trims,
like team tools and featuredTool. The fixture edit in the cross-reference
tests now throws when it does not apply, the cap tests cover the second
metric, and CLAUDE.md lists partner.tool among the strict cross-refs.
@wab
wab merged commit fe33d76 into main Oct 22, 2026
3 checks passed
@wab
wab deleted the claude/challenge-partner-block-c3bf9c branch October 22, 2026 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Partner block in the challenge schema

1 participant