found the issue

Turned out that the cwd path was always being appended to the pathname of the
file. I'm surprised this worked for anybody. 

Although it does make sense if other people's npm executables were in a location that happened to be a parent of the code they were testing? Maybe?