[gexiv2] test: Clean up after python tests
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gexiv2] test: Clean up after python tests
- Date: Mon, 5 Jun 2017 14:47:22 +0000 (UTC)
commit e29355502f6b578a7aeee179944afc6b906b8571
Author: Jens Georg <mail jensge org>
Date: Mon Jun 5 12:22:02 2017 +0200
test: Clean up after python tests
test/python/test_metadata.py | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/test/python/test_metadata.py b/test/python/test_metadata.py
index 5f7589a..e46c48b 100644
--- a/test/python/test_metadata.py
+++ b/test/python/test_metadata.py
@@ -45,12 +45,11 @@ class TestMetadata(unittest.TestCase):
self.metadata = GExiv2.Metadata()
self.metadata.open_path(self.get_input_file())
self.output_dir = tempfile.mkdtemp()
- self.output_file = os.path.join(self.output_dir, 'withgps.jpg')
+ self.output_file = 'withgps.jpg'
def tearDown(self):
try:
- os.remove(self.output_file)
- os.rmdir(self.output_dir)
+ shutil.rmtree(self.output_dir)
except Exception as e:
if e.errno != errno.ENOENT:
raise
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]