Skip to content

Commit

Permalink
Merge pull request #52992 from twangboy/fix_test_win_system
Browse files Browse the repository at this point in the history
Fix `unit.modules.test_win_system` tests
  • Loading branch information
dwoz authored May 14, 2019
2 parents b225839 + a1f08cd commit 2ccb650
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/unit/modules/test_win_system.py
Original file line number Diff line number Diff line change
Expand Up @@ -290,11 +290,11 @@ def test_get_pending_computer_name(self):
with patch.object(win_system, 'get_computer_name',
MagicMock(return_value='salt')):
reg_mock = MagicMock(return_value={'vdata': 'salt'})
with patch.dict(win_system.__salt__, {'reg.read_value': reg_mock}):
with patch.dict(win_system.__utils__, {'reg.read_value': reg_mock}):
self.assertFalse(win_system.get_pending_computer_name())

reg_mock = MagicMock(return_value={'vdata': 'salt_pending'})
with patch.dict(win_system.__salt__, {'reg.read_value': reg_mock}):
with patch.dict(win_system.__utils__, {'reg.read_value': reg_mock}):
self.assertEqual(win_system.get_pending_computer_name(),
'salt_pending')

Expand Down

0 comments on commit 2ccb650

Please sign in to comment.