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

"yarn test" coughs a hard error #104

Closed
MikeTheCanuck opened this issue Dec 5, 2017 · 1 comment
Closed

"yarn test" coughs a hard error #104

MikeTheCanuck opened this issue Dec 5, 2017 · 1 comment

Comments

@MikeTheCanuck
Copy link
Owner

While adding my first additional unit test, I tried to verify that yarn test would work in my local environment and show this next test working.

Instead, it coughed hard - and even without the new test:

$ yarn test
yarn run v1.3.2
$ react-scripts test --env=jsdom
2017-12-05 12:42 node[28987] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
2017-12-05 12:42 node[28987] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
2017-12-05 12:42 node[28987] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
events.js:183
      throw er; // Unhandled 'error' event
      ^

Error: Error watching file for changes: EMFILE
    at _errnoException (util.js:1024:11)
    at FSEvent.FSWatcher._handle.onchange (fs.js:1351:9)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Mikes-MacBook-Pro15:WhoDidITalkTo mike$ yarn test
yarn run v1.3.2
$ react-scripts test --env=jsdom
2017-12-05 12:43 node[29017] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
2017-12-05 12:43 node[29017] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
2017-12-05 12:43 node[29017] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-22)
events.js:183
      throw er; // Unhandled 'error' event
      ^

Error: Error watching file for changes: EMFILE
    at _errnoException (util.js:1024:11)
    at FSEvent.FSWatcher._handle.onchange (fs.js:1351:9)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
@MikeTheCanuck
Copy link
Owner Author

And apparently this is one solution that has worked for some (installing watchman tool):
facebook/create-react-app#871

In fact, that guidance has migrated to the React Scripts README, though it's implied rather than called out directly.

Once I ran brew install watchman, the next execution of yarn test worked like a charm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant