Skip to content
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

test: update fakeFS.read as graceful-fs uses it #1127

Merged
merged 1 commit into from Jan 13, 2022
Merged

Conversation

lamweili
Copy link
Contributor

graceful-fs@4.2.5 broke it as it changed to use Object.setPrototypeOf(read, fs$read).

-L136    read.__proto__ = fs$read
+L136    if (Object.setPrototypeOf) Object.setPrototypeOf(read, fs$read)

(isaacs/node-graceful-fs@c55c1b8#diff-f740ecac46b2fdaa68156b133262813aa6f66218b11d8709bab83580e76e486dR136)

When fakeFS.read is undefined, it now throws an error as Object.setPrototypeOf doesn't accept undefined in its parameters.

graceful-fs broke it as it changed to use `Object.setPrototypeOf(read, fs$read`).

isaacs/node-graceful-fs@c55c1b8#diff-f740ecac46b2fdaa68156b133262813aa6f66218b11d8709bab83580e76e486dR136

What this means is that, if `fakeFS.read` is `undefined`, it throws an error as `Object.setPrototypeOf` doesn't accept `undefined` in its parameters.
@lamweili lamweili added the tests Test issues or coverage label Jan 13, 2022
@lamweili lamweili added this to the 6.4.0 milestone Jan 13, 2022
@lamweili lamweili merged commit 25c17ad into master Jan 13, 2022
@lamweili lamweili deleted the update-test branch January 13, 2022 18:51
@lamweili lamweili added the dependencies Pull requests that update a dependency file label Jan 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file tests Test issues or coverage
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant