Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions src/lib/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,21 @@ const YOUTUBE_CLIENT_VERSION = '2.20260415.01.00';
// ==================== CERTIFICATION EXAM (full disable) ====================
// Proctored certification exams — extension must NOT run at all.
// The extension could be flagged as a cheating tool during proctored exams.
//
// Live URL verified 2026-05-11:
// https://anthropic.skilljar.com/claude-certified-architect-foundations-access-request
// Patterns also cover the public CCAF / CCA abbreviations seen in
// third-party prep guides, and Skilljar's `*-foundations-access-request`
// shape (used for any future cert tier — Professional, Expert, etc.).

const CERT_DISABLE_PATTERNS = [
/\/claude-certified/i,
/\/certified-architect/i,
/\/certification-exam/i,
/\/certified.*access-request/i,
/foundations-access-request/i,
/[/-]cca-?(?:foundations|professional|expert|associate)\b/i,
/\/ccaf\b/i,
/[?&]type=certification/i,
/\/proctored\b/i,
];
Expand Down
20 changes: 20 additions & 0 deletions tests/content-helpers.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,26 @@ describe('exam / cert URL patterns (production)', () => {
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/proctored'))).toBe(true);
});

test('cert patterns match the live CCA-Foundations access-request URL', () => {
// Verified live 2026-05-11 — this is the actual cert entry point.
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/claude-certified-architect-foundations-access-request'))).toBe(
true,
);
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/claude-certified-architect-foundations'))).toBe(true);
});

test('cert patterns match future cert-tier variants', () => {
// Forward-compat: Anthropic's cert ladder is likely Foundations →
// Associate → Professional → Expert. Catch the abbreviation set
// already used in third-party prep guides plus the Skilljar
// access-request URL shape.
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/cca-foundations'))).toBe(true);
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/cca-professional'))).toBe(true);
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/cca-expert'))).toBe(true);
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/ccaf'))).toBe(true);
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/anthropic-architect-foundations-access-request'))).toBe(true);
});

test('cert patterns do not match normal course URLs', () => {
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/courses/prompt-engineering'))).toBe(false);
expect(CERT_DISABLE_PATTERNS.some((p) => p.test('/courses/claude-overview'))).toBe(false);
Expand Down
Loading