New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add test for ls() on a symlink to a directory #795
Comments
Hello. I tried to come up a patch for this issue but I found out something interesting. In short, I believe these issue is already covered by https://github.com/shelljs/shelljs/blob/master/test/ls.js#L333. The report of codecov might be false negative. I did the following things:
For ls.js, there is only https://github.com/shelljs/shelljs/blob/master/src/ls.js#64 is not covered, because this test is not run on Windows. node_modules/.bin/nyc --reporter=html --reporter=lcov node_modules/.bin/ava test/*.js I put the html format report here.
Anyway, I'll try to find a linux machine and run test coverage to see if I can reproduce the same result. |
Looks like you're right! I guess we should figure out the false negative then. Thanks for starting the investigation. As an idea: you could put |
Well, that's strange. This does indeed seem to be a codecov bug (nyc reports coverage correctly). Thanks @dwi2 for catching this! In that case, I would welcome a PR to add |
This is one of our missing areas of coverage: https://codecov.io/gh/shelljs/shelljs/src/a187bd1b36ce28a5af214607257506ee28e1beb6/src/ls.js#L80
This shouldn't be too tricky to test, but I'm not sure if extra precautions need to be taken for Windows.
The text was updated successfully, but these errors were encountered: