Skip to content
This repository has been archived by the owner on May 22, 2024. It is now read-only.

Mocked stdin should be closed to avoid hanging forever #26

Closed
wants to merge 1 commit into from

Conversation

tchaumeny
Copy link

See #25

Added tests to ensure stdin end event is triggered (previously failing)

@jdx
Copy link
Collaborator

jdx commented May 14, 2019

This is not typical behavior when attached to the file. Usually the file stays open and does not close.

@tchaumeny
Copy link
Author

tchaumeny commented May 14, 2019

This is not typical behavior when attached to the file. Usually the file stays open and does not close.

What do you mean "when attached to the file" ?

In my case, I developed a CLI application and it can take inputs from stdin, but the application will hang until stdin sends an EOF. mock-stdin gives us a way to emulate the EOF using stdin.end() but we have no way to call it with the current implementation in fancy-test.

@jdx
Copy link
Collaborator

jdx commented May 14, 2019 via email

@RasPhilCo
Copy link
Contributor

Cleaning up - if you think this PR is still valid, reopen it. Thanks!

@RasPhilCo RasPhilCo closed this Dec 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants