def test_down(self): """ Test to shutdown a network interface """ with patch.dict(rh_ip.__salt__, {"cmd.run": MagicMock(return_value="A")}): self.assertEqual(rh_ip.down("iface", "iface_type"), "A") self.assertEqual(rh_ip.down("iface", "slave"), None)
def test_down(self): ''' Test to shutdown a network interface ''' with patch.dict(rh_ip.__salt__, {'cmd.run': MagicMock(return_value='A')}): self.assertEqual(rh_ip.down('iface', 'iface_type'), 'A') self.assertEqual(rh_ip.down('iface', 'slave'), None)