Skip to content

Commit

Permalink
Merge pull request #24 from zopefoundation/resourcewarnings
Browse files Browse the repository at this point in the history
Fix a ResourceWarning under Python 3 tests.
  • Loading branch information
jamadden committed Nov 13, 2017
2 parents 33d6f5f + 394fce9 commit 6109bf3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/zope/publisher/tests/test_http.py
Expand Up @@ -74,7 +74,8 @@ def getLogMessage(self):

# tempfiles have different types on different platforms, therefore use
# this "canonical" way of finding out the type.
TempFileType = tempfile.TemporaryFile().__class__
with tempfile.TemporaryFile() as t:
TempFileType = t.__class__

class HTTPInputStreamTests(unittest.TestCase):

Expand Down

0 comments on commit 6109bf3

Please sign in to comment.