appium/appium-instruments — pull request #7 by sebv (2014-03-21 06:44:21+00:00)
Title: smarter socket timeouts (Do not merge yet, for feedback only)

I've been experimenting with this recently, this adds granularity to the launch timeout, speeding up the relaunch process in case of failure.

With IOS 7.1 90% (if not 99%) of the failure happen after the simulator has been launched and it takes only 5 seconds (or less) wait to know that it had failed. By using 2 timeouts you can improve reliability (increasing global timeout), and average launch speed (with afterSimLaunch timeout) at the same time.

To try this up use appium master and for example:
```
export LAUNCH_TIMEOUT='{"global": 60000, "afterSimLaunch": 5000}'
DEVICE=ios7 mocha -t 90000 -R spec test/functional/ios/testapp/find-element-specs.js -g '@skip-ios7|@skip-ios-all' -i
```

Haven't tested it for versions below 7.1, but by default it doesn't impact current behavior.