{"action":"created","issue":{"url":"https://api.github.com/repos/facebook/jest/issues/1840","repository_url":"https://api.github.com/repos/facebook/jest","labels_url":"https://api.github.com/repos/facebook/jest/issues/1840/labels{/name}","comments_url":"https://api.github.com/repos/facebook/jest/issues/1840/comments","events_url":"https://api.github.com/repos/facebook/jest/issues/1840/events","html_url":"https://github.com/facebook/jest/issues/1840","id":180498199,"number":1840,"title":"Cannot find module 'ReactNativeDefaultInjection' from 'setup.js'","user":{"login":"shixukai","id":12314563,"avatar_url":"https://avatars.githubusercontent.com/u/12314563?v=3","gravatar_id":"","url":"https://api.github.com/users/shixukai","html_url":"https://github.com/shixukai","followers_url":"https://api.github.com/users/shixukai/followers","following_url":"https://api.github.com/users/shixukai/following{/other_user}","gists_url":"https://api.github.com/users/shixukai/gists{/gist_id}","starred_url":"https://api.github.com/users/shixukai/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shixukai/subscriptions","organizations_url":"https://api.github.com/users/shixukai/orgs","repos_url":"https://api.github.com/users/shixukai/repos","events_url":"https://api.github.com/users/shixukai/events{/privacy}","received_events_url":"https://api.github.com/users/shixukai/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2016-10-02T06:29:19Z","updated_at":"2016-10-28T03:33:22Z","closed_at":"2016-10-03T06:40:52Z","body":"```\r\n FAIL  __tests__/App-test.js\r\n  ● Test suite failed to run\r\n\r\n    Cannot find module 'ReactNativeDefaultInjection' from 'setup.js'\r\n\r\n      at Resolver.resolveModule (node_modules/jest-resolve/build/index.js:142:17)\r\n\r\nTest Summary\r\n › Ran all tests.\r\n › 1 test suite failed, 0 tests passed (0 total in 1 test suite, run time 0.242s)\r\nnpm ERR! Test failed.  See above for more details.\r\n```\r\n\r\nhere is my config of jest\r\n\r\n```js\r\n  \"jest\": {\r\n    \"preset\": \"jest-react-native\",\r\n    \"preprocessorIgnorePatterns\": [\r\n      \"node_modules/(?!react-native|jpush-react-native)\"\r\n    ],\r\n    \"haste\": {\r\n      \"defaultPlatform\": \"ios\",\r\n      \"platforms\": [\r\n        \"ios\",\r\n        \"android\"\r\n      ]\r\n    },\r\n    \"modulePathIgnorePatterns\": [\r\n      \"react\",\r\n      \"react-native\"\r\n    ],\r\n    \"moduleFileExtensions\": [\r\n      \"js\",\r\n      \"jsx\"\r\n    ],\r\n    \"collectCoverage\": false,\r\n    \"verbose\": true,\r\n    \"testPathIgnorePatterns\": [\r\n      \"/node_modules/\",\r\n      \".+/(resources)/.+\",\r\n      \".+/(autoMockOff.js)\"\r\n    ]\r\n  },\r\n```\r\n\r\n```js\r\n  \"devDependencies\": {\r\n    \"babel-jest\": \"^15.0.0\",\r\n    \"babel-plugin-module-resolver\": \"^2.0.0\",\r\n    \"babel-polyfill\": \"^6.16.0\",\r\n    \"babel-preset-react-native\": \"^1.9.0\",\r\n    \"babel-preset-react-native-stage-0\": \"^1.0.1\",\r\n    \"jest\": \"^15.1.1\",\r\n    \"jest-react-native\": \"^15.0.0\",\r\n    \"react-test-renderer\": \"^15.3.2\",\r\n    \"remote-redux-devtools\": \"^0.4.7\"\r\n  }\r\n\r\n```\r\nany idea?"},"comment":{"url":"https://api.github.com/repos/facebook/jest/issues/comments/256828288","html_url":"https://github.com/facebook/jest/issues/1840#issuecomment-256828288","issue_url":"https://api.github.com/repos/facebook/jest/issues/1840","id":256828288,"user":{"login":"cpojer","id":13352,"avatar_url":"https://avatars.githubusercontent.com/u/13352?v=3","gravatar_id":"","url":"https://api.github.com/users/cpojer","html_url":"https://github.com/cpojer","followers_url":"https://api.github.com/users/cpojer/followers","following_url":"https://api.github.com/users/cpojer/following{/other_user}","gists_url":"https://api.github.com/users/cpojer/gists{/gist_id}","starred_url":"https://api.github.com/users/cpojer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cpojer/subscriptions","organizations_url":"https://api.github.com/users/cpojer/orgs","repos_url":"https://api.github.com/users/cpojer/repos","events_url":"https://api.github.com/users/cpojer/events{/privacy}","received_events_url":"https://api.github.com/users/cpojer/received_events","type":"User","site_admin":false},"created_at":"2016-10-28T03:33:22Z","updated_at":"2016-10-28T03:33:22Z","body":"Yes, `testPathDirs` is actually a different name for \"roots\". We should really rename this and fix it. Jest only looks in folders that are called \"testPathDirs\" and it doesn't look anywhere else."}}
{"actor":{"display_login":"cpojer"}}