示例#1
0
 def test_set_auth_traps_enabled(self):
     '''
     Test - Manage the sending of authentication traps.
     '''
     mock_value = MagicMock(return_value=True)
     kwargs = {'status': True}
     with patch.dict(win_snmp.__salt__, {'reg.set_value': mock_value}):
         self.assertTrue(win_snmp.set_auth_traps_enabled(**kwargs))
示例#2
0
 def test_set_auth_traps_enabled(self):
     '''
     Test - Manage the sending of authentication traps.
     '''
     mock_value = MagicMock(return_value=True)
     kwargs = {'status': True}
     with patch.dict(win_snmp.__salt__, {'reg.set_value': mock_value}):
         self.assertTrue(win_snmp.set_auth_traps_enabled(**kwargs))
示例#3
0
 def test_set_auth_traps_enabled(self):
     """
     Test - Manage the sending of authentication traps.
     """
     mock_value = MagicMock(return_value=True)
     kwargs = {'status': True}
     with patch.dict(win_snmp.__utils__, {'reg.set_value': mock_value}), \
             patch('salt.modules.win_snmp.get_auth_traps_enabled',
                   MagicMock(return_value=True)):
         self.assertTrue(win_snmp.set_auth_traps_enabled(**kwargs))
示例#4
0
 def test_set_auth_traps_enabled(self):
     """
     Test - Manage the sending of authentication traps.
     """
     mock_value = MagicMock(return_value=True)
     kwargs = {"status": True}
     with patch.dict(win_snmp.__salt__,
                     {"reg.set_value": mock_value}), patch(
                         "salt.modules.win_snmp.get_auth_traps_enabled",
                         MagicMock(return_value=True)):
         self.assertTrue(win_snmp.set_auth_traps_enabled(**kwargs))