added test for connectFails, added exception parameter for connectFails