-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Rule: Test-Only Change Detection
Overview
Identifies PRs that modify only test files without touching any source code.
Label Metadata
- Label Name:
test-only-change - Color:
c5def5(Light Blue) - Description: Only test files modified in this PR
Detection Logic
- All modified files match test file patterns
- No source code files changed
- Can include test utilities, fixtures, mocks
File Patterns
Test files:
**/test/**/*,**/__tests__/**/***/*.test.js,**/*.spec.js**/*_test.rb,**/test_*.py**/*Test.java**/*.test.tsx**/fixtures/****/mocks/**
Exclude as source:
- Any file matching test patterns above
Example Scenarios
Triggers:
- Modified:
src/utils.test.js,tests/helpers.test.js - Modified:
__tests__/api.test.ts
Does NOT trigger:
- Modified:
src/utils.test.js,src/utils.js - Modified:
README.md(only docs)
Test Cases Needed
- Detects when all files are test files
- Does NOT trigger when source files also changed
- Handles mixed test file types
- Handles test fixtures/mocks
- Ignores documentation/config in test-only PRs
Edge Cases
- Only test config changed (jest.config.js) - consider if test file
- Test utilities changed - should trigger
- Test data/fixtures changed - should trigger
Priority
Medium - Useful for test improvement tracking
Status: Not implemented
Category: Test Coverage & Quality
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels