aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorMatěj Cepl <mcepl@redhat.com>2012-03-08 23:29:28 +0100
committerMatěj Cepl <mcepl@redhat.com>2012-03-08 23:29:28 +0100
commit884614e79eb99d216eb998a4ca9f504e07667a5f (patch)
treeff7de8943b83eaa1e92137cb5ea5e8206c7de78e /test
parentbf17bdcec33de1b1218849134ed7ae468f75e946 (diff)
downloadyamlish-884614e79eb99d216eb998a4ca9f504e07667a5f.tar.gz
Don't leak tempfiles (and setup.py test should actually do something).0.3
Diffstat (limited to 'test')
-rw-r--r--test/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/__init__.py b/test/__init__.py
index cf6dcde..83cdd6d 100644
--- a/test/__init__.py
+++ b/test/__init__.py
@@ -63,7 +63,7 @@ def _create_output_test(test_src, tested_function):
logging.debug("out:\n%s", textwrap.dedent(test_src['out']))
want = yaml.load(textwrap.dedent(test_src['out']))
logging.debug("want:\n%s", want)
- with tempfile.NamedTemporaryFile(delete=False) as test_file:
+ with tempfile.NamedTemporaryFile() as test_file:
tested_function(test_src['in'], test_file)
test_file.seek(0)
got_str = test_file.read()