[tests/caffeine] Add unit tests for caffeine

This commit is contained in:
Tobi-wan Kenobi 2017-03-05 11:48:33 +01:00
parent aaaf62673d
commit e6d44e7898
2 changed files with 70 additions and 1 deletions

View file

@ -54,7 +54,7 @@ class MockPopen(object):
self.mock.returncode = 0
def assert_call(self, cmd):
self.mock.popen.assert_called_with(shlex.split(cmd), stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
self.mock.popen.assert_any_call(shlex.split(cmd), stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
def cleanup(self):
self._patch.stop()