summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2011-12-06 15:49:42 (GMT)
committerDavid Malcolm <dmalcolm@redhat.com>2011-12-06 15:49:42 (GMT)
commit45e4af0b775bb15cdf8cefa2348f501f825fec2c (patch)
tree09bc834bf838f04b3d04b60fb9550cfaba67fd83
parent920afc4a566ba3096b0d24de72212480621e61e7 (diff)
downloadpython-pylons-45e4af0b775bb15cdf8cefa2348f501f825fec2c.zip
python-pylons-45e4af0b775bb15cdf8cefa2348f501f825fec2c.tar.gz
python-pylons-45e4af0b775bb15cdf8cefa2348f501f825fec2c.tar.xz
Fix test_langs failure (rhbz#715777)
-rw-r--r--fix-test_langs.patch9
-rw-r--r--python-pylons.spec14
2 files changed, 22 insertions, 1 deletions
diff --git a/fix-test_langs.patch b/fix-test_langs.patch
new file mode 100644
index 0000000..7cff82d
--- /dev/null
+++ b/fix-test_langs.patch
@@ -0,0 +1,9 @@
+diff -up Pylons-1.0/tests/test_units/test_basic_app.py.fix-test_langs Pylons-1.0/tests/test_units/test_basic_app.py
+--- Pylons-1.0/tests/test_units/test_basic_app.py.fix-test_langs 2011-12-06 10:41:16.777048557 -0500
++++ Pylons-1.0/tests/test_units/test_basic_app.py 2011-12-06 10:42:20.977044166 -0500
+@@ -91,4 +91,4 @@ class TestJsonifyDecorator(object):
+ def test_langs(self):
+ response = self.app.get(url(controller='i18nc', action='langs'), headers={
+ 'Accept-Language':'fr;q=0.6, en;q=0.1, ja;q=0.3'})
+- assert "['fr', 'ja', 'en', 'en-us']" in response
++ assert "['fr', 'ja', 'en-us']" in response
diff --git a/python-pylons.spec b/python-pylons.spec
index 43a7ade..f73dc16 100644
--- a/python-pylons.spec
+++ b/python-pylons.spec
@@ -2,13 +2,21 @@
Name: python-pylons
Version: 1.0
-Release: 3%{?dist}
+Release: 4%{?dist}
Summary: Pylons web framework
Group: Development/Languages
License: BSD
URL: http://www.pylonshq.com/
Source0: http://pypi.python.org/packages/source/P/Pylons/Pylons-%{version}.tar.gz
+
+# Fix failing test:
+# tests.test_units.test_basic_app.TestJsonifyDecorator.test_langs
+# Adapted from
+# https://github.com/Pylons/pylons/commit/0789e367113f75c41170ba2fbf8250a0390e633f
+# (rhbz#715777)
+Patch1: fix-test_langs.patch
+
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: python-setuptools-devel
@@ -56,6 +64,7 @@ website development in Python easy. Several key points:
%prep
%setup -q -n Pylons-%{version}
+%patch1 -p1
%build
%{__python} setup.py build
@@ -81,6 +90,9 @@ rm -rf %{buildroot}
%changelog
+* Tue Dec 6 2011 David Malcolm <dmalcolm@redhat.com> - 1.0-4
+- fix test_langs failure (rhbz#715777)
+
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild