Bug 1033402 - Part 1: waitForSocket() before connecting to marionette.
Bug 1033402 - Part 2: unit test for the waitForSocket.
Merge pull request #115 from hfiguiere/bug1033402

Bug 1033402 - waitForSocket() before connecting to marionette. r=jlal