Skip to content

chore: add no-source-scanning test rule to CLAUDE.md#1130

Merged
jdalton merged 1 commit intomainfrom
chore/no-source-scanning-test-rule
Mar 26, 2026
Merged

chore: add no-source-scanning test rule to CLAUDE.md#1130
jdalton merged 1 commit intomainfrom
chore/no-source-scanning-test-rule

Conversation

@jdalton
Copy link
Contributor

@jdalton jdalton commented Mar 26, 2026

Summary

  • Adds a "Test Style — Functional Over Source Scanning" rule to the Testing section of CLAUDE.md
  • Prohibits writing tests that read source files and assert on string contents (.toContain('pattern'))
  • Directs toward functional tests (behavior verification), integration tests (built binary), and unit tests (real function calls)

Test plan

  • Verify the new rule appears in the Testing section of CLAUDE.md
  • Confirm no other files were modified

Note

Low Risk
Low risk; this PR only updates developer documentation with testing guidance and does not change runtime code or test execution.

Overview
Adds a new “Test Style — Functional Over Source Scanning” section to CLAUDE.md that explicitly forbids tests which read source files and assert on string patterns (e.g., .toContain('pattern')).

Updates the testing guidance to steer contributors toward behavior-based functional tests, integration tests for built binaries, and unit tests that call real functions.

Written by Cursor Bugbot for commit c558ec6. Configure here.

@jdalton jdalton enabled auto-merge (squash) March 26, 2026 13:13
@jdalton jdalton merged commit e2bee79 into main Mar 26, 2026
6 checks passed
@jdalton jdalton deleted the chore/no-source-scanning-test-rule branch March 26, 2026 13:24
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.

2 participants