Exemplo n.º 1
0
 def test_clear(self):
     """
     Test if it clear out all of the data in the minion datastore
     """
     with patch("os.remove", MagicMock(return_value="")):
         with patch.dict(data.__opts__, {"cachedir": ""}):
             self.assertTrue(data.clear())
Exemplo n.º 2
0
 def test_clear(self):
     '''
     Test if it clear out all of the data in the minion datastore
     '''
     with patch('os.remove', MagicMock(return_value='')):
         with patch.dict(data.__opts__, {'cachedir': ''}):
             self.assertTrue(data.clear())
Exemplo n.º 3
0
 def test_clear(self):
     '''
     Test if it clear out all of the data in the minion datastore
     '''
     mock = MagicMock(return_value='')
     with patch.dict(data.__opts__, {'cachedir': mock}):
         self.assertTrue(data.clear())