Throw exceptions when "connect" fails
Readded test