check if connection is actually established

This checks if connection is actually established and returns assigned IP address if is, or throws `ConnectionFail` if not.

@rockymeza - yes, please add failing tests as you've proposed and I'll try to figure out how to make it not failing.