def main(argv): """ The main program """ try: #pylint: disable=unused-variable opts, args = getopt.getopt(argv, "h", ["help"]) except getopt.GetoptError: usage() #pylint: disable=unused-variable for opt, val in opts: if opt in ('-h', '--help'): usage() print('Testing the machines') my_host = Machine() my_host.set_name('hurukan') my_host.set_ip_nbr('132.166.28.183') print(my_host.get_id())
def test_get_id(): """ Returns the identity of the machine """ host = Machine() assert host.get_id() == 'Host : localhost 127.0.0.1'