[Python-modules-commits] [twisted] 14/16: handle-setlocale-test-failure

Free Ekanayaka freee at moszumanska.debian.org
Mon Aug 28 17:40:04 UTC 2017


This is an automated email from the git hooks/post-receive script.

freee pushed a commit to branch patch-queue/master
in repository twisted.

commit b248d682e5c1a9c1eb65d7103ac2208a435a6981
Author: Free Ekanayaka <freee at debian.org>
Date:   Sat Feb 18 13:50:23 2017 +0000

    handle-setlocale-test-failure
    
    Gracefully handle setlocale failures during the test suite (e.g
    when running in a container).
    
    Gbp-Pq: Name 0010-handle-setlocale-test-failure.patch
---
 src/twisted/conch/test/test_cftp.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/twisted/conch/test/test_cftp.py b/src/twisted/conch/test/test_cftp.py
index d24714e..01c7630 100644
--- a/src/twisted/conch/test/test_cftp.py
+++ b/src/twisted/conch/test/test_cftp.py
@@ -200,8 +200,10 @@ class ListingTests(TestCase):
             locale.setlocale(locale.LC_ALL, "es_AR.UTF8")
         except locale.Error:
             test_localeIndependent.skip = "The es_AR.UTF8 locale is not installed."
-    finally:
-        locale.setlocale(locale.LC_ALL, currentLocale)
+        else:
+            locale.setlocale(locale.LC_ALL, currentLocale)
+    except:
+        pass
 
 
     def test_newSingleDigitDayOfMonth(self):

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/twisted.git



More information about the Python-modules-commits mailing list