[tor-commits] [stem/master] Ignore vim swap files for installation integ test

atagar at torproject.org atagar at torproject.org
Sun Dec 6 21:57:12 UTC 2015


commit ffa61f8b1a6952fd85f27b4b9bea44abe4ef9bdb
Author: Damian Johnson <atagar at torproject.org>
Date:   Tue Dec 1 09:55:27 2015 -0800

    Ignore vim swap files for installation integ test
    
    We have a new test that asserts that everything in the stem directory gets
    installed. Vim swap files are an obvious exception - ignoring those...
    
      ======================================================================
      FAIL: test_installs_all_files
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "/home/atagar/Desktop/stem/test/integ/installation.py", line 93, in test_installs_all_files
          self.fail("The following files were expected to be in our installation but weren't. Maybe our setup.py needs to be updated?\n\n%s" % '\n'.join(missing))
      AssertionError: The following files were expected to be in our installation but weren't. Maybe our setup.py needs to be updated?
    
      stem/.manual.py.swp
    
      ----------------------------------------------------------------------
      Ran 2 tests in 0.432s
---
 test/integ/installation.py |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/integ/installation.py b/test/integ/installation.py
index 6b0f759..986fb3c 100644
--- a/test/integ/installation.py
+++ b/test/integ/installation.py
@@ -78,7 +78,7 @@ class TestInstallation(unittest.TestCase):
 
     for root, dirnames, filenames in os.walk(os.path.join(BASE_DIRECTORY, 'stem')):
       for filename in filenames:
-        if not filename.endswith('.pyc'):
+        if not filename.endswith('.pyc') and not filename.endswith('.swp'):
           expected.add(os.path.join(root, filename)[len(BASE_DIRECTORY) + 1:])
 
     for root, dirnames, filenames in os.walk(self.site_packages_path):





More information about the tor-commits mailing list