Skip to content

Commit

Permalink
tests: Do GC after each test
Browse files Browse the repository at this point in the history
This makes it easier to understand which test causes
ResourceWarnings.
  • Loading branch information
1st1 committed Jul 5, 2016
1 parent f1d37c6 commit 32f5fc7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions uvloop/_testbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,11 @@ def setUp(self):
def tearDown(self):
self.loop.close()

# GC to show any resource warnings as the test completes
gc.collect()
gc.collect()
gc.collect()

if getattr(self.loop, '_debug_cc', False):
gc.collect()
gc.collect()
Expand Down

0 comments on commit 32f5fc7

Please sign in to comment.