diff options
author | Richard van der Hoff <richard@matrix.org> | 2016-03-03 11:39:25 +0000 |
---|---|---|
committer | Richard van der Hoff <richard@matrix.org> | 2016-03-03 11:39:25 +0000 |
commit | 79f34bdbc2720a832cdab36ba58e83201e549c41 (patch) | |
tree | 2bdadb2bd2d2dac1a6722c4d33ca81febb7d7ece /tests/utils.py | |
parent | Fix typo (diff) | |
parent | jenkins.sh: set -x (diff) | |
download | synapse-79f34bdbc2720a832cdab36ba58e83201e549c41.tar.xz |
Merge branch 'develop' into rav/SYN-642
Diffstat (limited to 'tests/utils.py')
-rw-r--r-- | tests/utils.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/utils.py b/tests/utils.py index bf7a31ff9e..dfbee5c23a 100644 --- a/tests/utils.py +++ b/tests/utils.py @@ -239,9 +239,10 @@ class MockClock(object): def looping_call(self, function, interval): pass - def cancel_call_later(self, timer): + def cancel_call_later(self, timer, ignore_errs=False): if timer[2]: - raise Exception("Cannot cancel an expired timer") + if not ignore_errs: + raise Exception("Cannot cancel an expired timer") timer[2] = True self.timers = [t for t in self.timers if t != timer] |