Commits

Robert Lehmann committed ab2fc1d

Transform false positives into skipped tests.

Comments (0)

Files changed (1)

tests/test_build_gettext.py

 from subprocess import Popen, PIPE
 
 from util import *
+from util import SkipTest
 
 
 def teardown_module():
                        '--locale', 'en_US'],
                         stdout=PIPE, stderr=PIPE)
         except OSError:
-            return  # most likely msginit was not found
+            raise SkipTest  # most likely msginit was not found
         else:
             stdout, stderr = p.communicate()
             if p.returncode != 0:
                 os.path.join('en', 'LC_MESSAGES', 'test_root.mo')],
                 stdout=PIPE, stderr=PIPE)
         except OSError:
-            return  # most likely msgfmt was not found
+            raise SkipTest  # most likely msgfmt was not found
         else:
             stdout, stderr = p.communicate()
             if p.returncode != 0:
             test_root / 'xx' / 'LC_MESSAGES' / 'subdir.mo'],
             stdout=PIPE, stderr=PIPE)
     except OSError:
-        return  # most likely msgfmt was not found
+        raise SkipTest  # most likely msgfmt was not found
     else:
         stdout, stderr = p.communicate()
         if p.returncode != 0: