{"action":"created","issue":{"url":"https://api.github.com/repos/wix/detox/issues/602","repository_url":"https://api.github.com/repos/wix/detox","labels_url":"https://api.github.com/repos/wix/detox/issues/602/labels{/name}","comments_url":"https://api.github.com/repos/wix/detox/issues/602/comments","events_url":"https://api.github.com/repos/wix/detox/issues/602/events","html_url":"https://github.com/wix/detox/issues/602","id":302623779,"number":602,"title":"detox test ios with error:  Timeout of 120000ms exceeded","user":{"login":"jykun","id":13287601,"avatar_url":"https://avatars0.githubusercontent.com/u/13287601?v=4","gravatar_id":"","url":"https://api.github.com/users/jykun","html_url":"https://github.com/jykun","followers_url":"https://api.github.com/users/jykun/followers","following_url":"https://api.github.com/users/jykun/following{/other_user}","gists_url":"https://api.github.com/users/jykun/gists{/gist_id}","starred_url":"https://api.github.com/users/jykun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jykun/subscriptions","organizations_url":"https://api.github.com/users/jykun/orgs","repos_url":"https://api.github.com/users/jykun/repos","events_url":"https://api.github.com/users/jykun/events{/privacy}","received_events_url":"https://api.github.com/users/jykun/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-03-06T09:28:55Z","updated_at":"2018-03-06T12:47:16Z","closed_at":null,"author_association":"NONE","body":"#### Description\r\n due to use react-native@0.53.0,  by.text can not run. then i update detox version (6.0.4->7.1.0),  and run `detox test` with error `Timeout of 120000ms exceeded. For async tests and hooks, ensure \"done()\" is called; if returning a Promise, ensure it resolves.`\r\n\r\n#### setup\r\n##### package.json\r\n```\r\n\"detox\": {\r\n    \"configurations\": {\r\n      \"ios.sim.debug\": {\r\n        \"binaryPath\": \"ios/build/Build/Products/Debug-iphonesimulator/JiJiaApp.app\",\r\n        \"build\": \"xcodebuild -workspace ios/JiJiaApp.xcworkspace -scheme JiJiaApp -configuration Debug -sdk iphonesimulator -derivedDataPath ios/build\",\r\n        \"type\": \"ios.simulator\",\r\n        \"name\": \"iPhone 7\"\r\n      }\r\n    }\r\n  },\r\n```\r\n##### mocha.opts\r\n```\r\n--recursive --timeout 120000 --bail\r\n```\r\n\r\n##### init\r\n```\r\nrequire('babel-polyfill')\r\nconst detox = require('detox')\r\nconst config = require('../package.json').detox\r\n\r\nbefore(async () => {\r\n  await detox.init(config, { launchApp: false })\r\n})\r\n\r\nafter(async () => {\r\n  await detox.cleanup()\r\n})\r\n```\r\n\r\n##### login.spec.js\r\n```\r\ndescribe('Login', () => {\r\n  before(async () => {\r\n    await device.launchApp({\r\n      permissions: {\r\n        notifications: 'YES',\r\n        calendar: 'YES',\r\n        photos: 'YES',\r\n        contacts: 'YES',\r\n      },\r\n    })\r\n\r\n    await device.reloadReactNative()\r\n    await device.setURLBlacklist([\r\n      '.*in.mobile.azure.com.*',\r\n    ])\r\n    await device.disableSynchronization()\r\n  })\r\n\r\n it('should have loginScreen screen', async () => {\r\n    await expect(element(by.id('loginScreen'))).toBeVisible()\r\n  })\r\n})\r\n```\r\n\r\n#### Detox, Node, Device, Xcode and macOS Versions\r\n\r\n* React-native: 0.53.0\r\n* Detox: 7.1.0\r\n* Node: 9.7.1\r\n* Device:  simularor iphone 7\r\n* Xcode:  9.1\r\n* macOS: high sierra 10.13.3\r\n\r\n#### Device and verbose Detox logs\r\n\r\n```\r\nlocalhost:app_reactnative Kun$ detox test\r\nnode_modules/.bin/mocha e2e --opts e2e/mocha.opts       \r\n\r\n\r\ndetox-server info 16:56:17: server listening on localhost:54215...\r\ndetox info 1: Searching for device matching iPhone 7... \r\ndetox info 3: Uninstalling cn.tuofeng.jijia... \r\ndetox info 3: cn.tuofeng.jijia uninstalled \r\ndetox info 4: Installing /Users/Kun/jijia_app_reactnative/ios/build/Build/Products/Debug-iphonesimulator/JiJiaApp.app... \r\ndetox info 4: /Users/Kun/jijia_app_reactnative/ios/build/Build/Products/Debug-iphonesimulator/JiJiaApp.app installed \r\n  Login\r\ndetox info 5: Trying to set permissions... \r\ndetox info 5: Permissions are set \r\ndetox info 6: Launching cn.tuofeng.jijia... \r\ndetox info 6: cn.tuofeng.jijia launched. The stdout and stderr logs were recreated, you can watch them with:\r\n        tail -F $HOME/Library/Developer/CoreSimulator/Devices/0FE83482-0CDF-48B2-BDA8-E44EAE09EB47/data/tmp/detox.last_launch_app_log.{out,err} \r\n    1) \"before all\" hook\r\n\r\n  0 passing (2m)\r\n  1 failing\r\n\r\n  1) Login\r\n       \"before all\" hook:\r\n     Error: Timeout of 120000ms exceeded. For async tests and hooks, ensure \"done()\" is called; if returning a Promise, ensure it resolves.\r\n  \r\n\r\n\r\n\r\n\r\n\r\n  0 passing (2m)\r\n  1 failing\r\n\r\n  1) Login\r\n       \"before all\" hook:\r\n     Error: Timeout of 120000ms exceeded. For async tests and hooks, ensure \"done()\" is called; if returning a Promise, ensure it resolves.\r\n  \r\n\r\n\r\n\r\nchild_process.js:615\r\n    throw err;\r\n    ^\r\n\r\nError: Command failed: node_modules/.bin/mocha e2e --opts e2e/mocha.opts       \r\n    at checkExecSyncError (child_process.js:575:11)\r\n    at Object.execSync (child_process.js:612:13)\r\n    at runMocha (/Users/Kun/jijia_app_reactnative/node_modules/detox/local-cli/detox-test.js:72:6)\r\n    at Object.<anonymous> (/Users/Kun/jijia_app_reactnative/node_modules/detox/local-cli/detox-test.js:50:5)\r\n    at Module._compile (module.js:662:30)\r\n    at Object.Module._extensions..js (module.js:673:10)\r\n    at Module.load (module.js:575:32)\r\n    at tryModuleLoad (module.js:515:12)\r\n    at Function.Module._load (module.js:507:3)\r\n    at Function.Module.runMain (module.js:703:10)\r\n```"},"comment":{"url":"https://api.github.com/repos/wix/detox/issues/comments/370770563","html_url":"https://github.com/wix/detox/issues/602#issuecomment-370770563","issue_url":"https://api.github.com/repos/wix/detox/issues/602","id":370770563,"user":{"login":"LeoNatan","id":2270433,"avatar_url":"https://avatars3.githubusercontent.com/u/2270433?v=4","gravatar_id":"","url":"https://api.github.com/users/LeoNatan","html_url":"https://github.com/LeoNatan","followers_url":"https://api.github.com/users/LeoNatan/followers","following_url":"https://api.github.com/users/LeoNatan/following{/other_user}","gists_url":"https://api.github.com/users/LeoNatan/gists{/gist_id}","starred_url":"https://api.github.com/users/LeoNatan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LeoNatan/subscriptions","organizations_url":"https://api.github.com/users/LeoNatan/orgs","repos_url":"https://api.github.com/users/LeoNatan/repos","events_url":"https://api.github.com/users/LeoNatan/events{/privacy}","received_events_url":"https://api.github.com/users/LeoNatan/received_events","type":"User","site_admin":false},"created_at":"2018-03-06T12:47:16Z","updated_at":"2018-03-06T12:47:16Z","author_association":"MEMBER","body":"Did you set the testID on your component?"}}
{"actor":{"display_login":"LeoNatan"}}