def open_connection(self, port=None):
raise NotImplementedError("<STR_LIT>")<EOL>
open a TCP connection to service running in the container, if port is None and
container exposes only a single port, connect to it, otherwise raise an exception

:param port: int or None
:return: socket