Fixed some tests... maybe...

This commit is contained in:
twangboy 2015-07-24 09:40:46 -06:00
parent ff7296d983
commit b473fb7827

View File

@ -46,8 +46,8 @@ class RegTestCase(TestCase):
mock = MagicMock(side_effect=[value, 'a', 'a'])
mock_t = MagicMock(return_value=True)
with patch.dict(reg.__salt__, {'reg.read_key': mock,
'reg.set_key': mock_t}):
with patch.dict(reg.__salt__, {'reg.read_value': mock,
'reg.set_value': mock_t}):
self.assertDictEqual(reg.present(name, value), ret)
with patch.dict(reg.__opts__, {'test': True}):
@ -74,8 +74,8 @@ class RegTestCase(TestCase):
mock = MagicMock(side_effect=[False, True, True])
mock_t = MagicMock(return_value=True)
with patch.dict(reg.__salt__, {'reg.read_key': mock,
'reg.delete_key': mock_t}):
with patch.dict(reg.__salt__, {'reg.read_value': mock,
'reg.delete_value': mock_t}):
self.assertDictEqual(reg.absent(name), ret)
with patch.dict(reg.__opts__, {'test': True}):