changeset 187:b19bf5895a55

Use the FileTestMixin for the status tests, too.
author Bernhard Herzog <bh@intevation.de>
date Thu, 26 Jun 2008 16:38:09 +0000
parents 2622bf5ed5bd
children f72530307eea
files test/test_status.py
diffstat 1 files changed, 4 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/test/test_status.py	Thu Jun 26 16:33:14 2008 +0000
+++ b/test/test_status.py	Thu Jun 26 16:38:09 2008 +0000
@@ -1,4 +1,4 @@
-# Copyright (C) 2007 by Intevation GmbH
+# Copyright (C) 2007, 2008 by Intevation GmbH
 # Authors:
 # Bernhard Herzog <bh@intevation.de>
 #
@@ -15,17 +15,14 @@
 from treepkg.status import RevisionStatus, Status, EnumFieldDesc
 from treepkg.util import ensure_directory, writefile
 
+from filesupport import FileTestMixin
 
 
-class TestStatus(unittest.TestCase):
 
-    def tempfilename(self):
-        tempdir = os.path.join(os.path.dirname(__file__), "temp")
-        ensure_directory(tempdir)
-        return os.path.join(tempdir, self.id())
+class TestStatus(unittest.TestCase, FileTestMixin):
 
     def setUp(self):
-        self.filename = self.tempfilename()
+        self.filename = self.temp_file_name("status")
         if os.path.exists(self.filename):
             os.remove(self.filename)
 
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)