Closed rminnich closed 7 months ago
I'll fix these tests, they really should be updated to use errors.Is.
need to see how to do that in the context of this test framework.
I'll fix these tests, they really should be updated to use errors.Is.
@rminnich Feel free to add a commit to that effect or do a follow-up PR.
Thank you @rminnich! :bow:
Fixes #42
insideBaseDirEval would fail if baseDir was "/". Since "/" contains anything, and can never be a symlink, just return true, nil if baseDir is "/".
Add a simple test for this case.
Also, while we are at it, have the returned error be a lot more informative: show the name and the base diectory; further, have it wrap os.ErrNotExist should anyone wish to use errors.Is at some point.