def test_update(self): NAME = 'ovirtmgmt' net = docker.Network(NAME) net.update(nic='foonet0', gw='192.168.192.240', subnet='192.168.192.0', mask='26') self.assertEqual(net.subnet, "192.168.192.0/26")
def test_load_missing(self): NAME = 'notexists' net = docker.Network(NAME) net.load() self.assertFalse(net.existing)
def test_existing_false_before_load(self): NAME = 'test' net = docker.Network(NAME) self.assertFalse(net.existing)
def test_load(self): NAME = 'ovirtmgmt' net = docker.Network(NAME) net.load() self.assertTrue(net.existing)
def test_subnet(self): NAME = 'test' net = docker.Network(NAME) self.assertEqual(net.subnet, "10.1.0.0/20")