When testing a function whose job is to open files, the test will fail if another test file imports mock-fs.
I receive the following error:
Error: UNKNOWN: unknown error, open MOCKED-FILE-PATH-HERE
This error disappears and the test passes when I comment out the mock-fs import in another file. The other file simply needs to import mock-fs. It does not need to actually use the package for the tests to fail.
When testing a function whose job is to open files, the test will fail if another test file imports
mock-fs
.I receive the following error:
Error: UNKNOWN: unknown error, open MOCKED-FILE-PATH-HERE
This error disappears and the test passes when I comment out the mock-fs import in another file. The other file simply needs to import mock-fs. It does not need to actually use the package for the tests to fail.