test-only-export
an export only its own tests reference
Deterministic checkadvisory by defaultbasetests
The argument
An export whose only references anywhere are test files is a hint, not a violation: production never calls it, so it may be dead code wearing a test — or a deliberate promotion whose contract the tests pin. The finding asks the question; a human answers it.
The proof
fail
export const buildGreeting = ({ name }: { name: string }): string => `Hello, ${name}.`;
pass
{
"name": "test-only-export-pass-fixture",
"private": true,
"dependencies": {
"@tanstack/react-router": "1.168.3",
"@tanstack/react-start": "1.167.5"
}
}
Turn it down
Both lines go in your lightsout.config.json.
"standards-checks": { "test-only-export": "advisory" }"standards-checks": { "test-only-export": "off" }