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

All tests are failing #21

Closed
felquis opened this issue Nov 13, 2016 · 4 comments
Closed

All tests are failing #21

felquis opened this issue Nov 13, 2016 · 4 comments

Comments

@felquis
Copy link
Contributor

felquis commented Nov 13, 2016

When I run npm test I saw this messages

jest-haste-map: Watchman crawl failed. Retrying once with node crawler.
  Usually this happens when watchman isn't running. Create an empty `.watchmanconfig` file in your project's root folder or initialize a git or hg repository in your project.
  Error: Watchman error: unknown command watch-project. Make sure watchman is running for this project. See https://facebook.github.io/watchman/docs/troubleshooting.html.
No tests found related to files changed since last commit.

If I uninstall watchman with brew uninstall watchman then installing it again fixed the problem, but it does't throw erros, but the tests fail with

Couldn't find preset "es2015" relative to directory "/Users/felquis/project"

This is happening for any app created with create-react-app right now!

@felquis
Copy link
Contributor Author

felquis commented Nov 13, 2016

Removed .babelrc in the parent directory as suggested here facebook/create-react-app#949 (comment)

Now jest said there was no files to test, I figured out files with "Example" key word were ignored, renamed EveryExample.test.js to Every.test.js and the file was added to the tests.

@felquis
Copy link
Contributor Author

felquis commented Nov 13, 2016

image

Each test file is failing because Cannot find module 'extsprintf'

@felquis
Copy link
Contributor Author

felquis commented Nov 13, 2016

I fixed a syntax error in KeyDownExample.test.js and EveryExample.test.js, now extsprintf isn't the problem.

@felquis felquis mentioned this issue Nov 13, 2016
@felquis
Copy link
Contributor Author

felquis commented Nov 13, 2016

The only problem now is that we need to mock some resources! https://facebook.github.io/jest/docs/manual-mocks.html

investigation will continue at #23

@felquis felquis closed this as completed Nov 13, 2016
daniyuu added a commit to daniyuu/hello-react-native that referenced this issue Jan 9, 2017
[Watchman error]
jest-haste-map: Watchman crawl failed. Retrying once with node crawler.
  Usually this happens when watchman isn't running. Create an empty `.watchmanconfig` file in your project's root folder or initialize a git or hg repository in your project.
  Error: Watchman error: unknown command watch-project. Make sure watchman is running for this project. See https://facebook.github.io/watchman/docs/troubleshooting.html.
No tests found related to files changed since last commit.

Solutions
1. brew uninstall watchman, pagarme/react-event-components#21

[RCTPIlatform.m]
/node_modules/react-native/React/Base/RCTPlatform.m:26:10: Use of undeclared identifier 'UIUserInterfaceIdiomCarPlay'; did you mean 'UIUserInterfaceIdiomPad'?

Solutions:
facebook/react-native#11265
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