Skip to content

Commit

Permalink
remove context manager for assertRaises
Browse files Browse the repository at this point in the history
  • Loading branch information
alisaifee committed Oct 5, 2015
1 parent a9830d8 commit b204b45
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/test_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def test_redis_sentinel(self):
self.assertTrue(limiter.hit(per_min))

def test_pluggable_storage_invalid_construction(self):
with self.assertRaises(ConfigurationError):
def cons():
class _(Storage):
def incr(self, key, expiry, elastic_expiry=False):
return
Expand All @@ -115,6 +115,7 @@ def get(self, key):

def get_expiry(self, key):
return time.time()
self.assertRaises(ConfigurationError, cons)

def test_pluggable_storage_no_moving_window(self):
class MyStorage(Storage):
Expand Down

0 comments on commit b204b45

Please sign in to comment.