[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [bridgedb/master] Fix unittest failures in test_EmailServer due to creating an existent dir.



commit efeeb01627c73de3e70708744290c9a280048283
Author: Isis Lovecruft <isis@xxxxxxxxxxxxxx>
Date:   Tue Nov 19 08:34:27 2013 +0000

    Fix unittest failures in test_EmailServer due to creating an existent dir.
---
 lib/bridgedb/test/test_EmailServer.py |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lib/bridgedb/test/test_EmailServer.py b/lib/bridgedb/test/test_EmailServer.py
index bbcd1b9..913aa98 100644
--- a/lib/bridgedb/test/test_EmailServer.py
+++ b/lib/bridgedb/test/test_EmailServer.py
@@ -61,7 +61,9 @@ class EmailGnuPGTest(unittest.TestCase):
         self.runDir   = os.path.join(here, 'rundir')
         self.gpgFile  = os.path.join(topDir, 'gnupghome', 'TESTING.subkeys.sec')
         self.gpgMoved = os.path.join(here, 'TESTING.subkeys.sec')
-        os.makedirs(self.runDir)
+
+        if not os.path.isdir(self.runDir):
+            os.makedirs(self.runDir)
 
         configuration = {}
         TEST_CONFIG_FILE.seek(0)



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits