You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
includeAllFiles can add a duplicate placeholder on Windows when path casing differs #1018
While working on #360, a review turned up a related edge case in includeAllFiles (lib/task-utils.ts) that seemed worth tracking on its own rather than folding into that fix.
What happens
To decide whether a globbed file is already covered, includeAllFiles converts each covered entry's path to forward slashes and compares it to the tinyglobby path with an exact, case-sensitive string match. Windows paths aren't case-sensitive, though. So if the two sides disagree only on casing, for example the drive letter (c:\proj\src\a.js from the instrumenter vs C:/proj/src/a.js from the glob), the file isn't recognized as covered and gets a second, empty placeholder entry.
Why it matters
The same file then shows up twice in the report, once with real coverage and once at 0%. That drags the totals down and can make --check-coverage fail.
Status
I haven't reproduced this in a real run yet. It comes from reading the code, so the first step is confirming which setups actually produce mismatched casing (Git Bash vs cmd.exe working directories are a likely suspect). If it's real, a fix could compare a case-folded form of the path on Windows only, leaving POSIX matching untouched.
Activity