def test_interfaces(self): """ Test for Returns interfaces attached to a bridge """ self.assertEqual(bridge.interfaces(), None) mock = MagicMock(return_value={"interfaces": "A"}) with patch.object(bridge, "_os_dispatch", mock): self.assertEqual(bridge.interfaces("br"), "A")
def test_interfaces(self): ''' Test for Returns interfaces attached to a bridge ''' self.assertEqual(bridge.interfaces(), None) mock = MagicMock(return_value={'interfaces': 'A'}) with patch.object(bridge, '_os_dispatch', mock): self.assertEqual(bridge.interfaces('br'), 'A')