Hello community,

here is the log from the commit of package python-WebTest for openSUSE:Factory 
checked in at 2019-03-04 09:09:27
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-WebTest (Old)
 and      /work/SRC/openSUSE:Factory/.python-WebTest.new.28833 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-WebTest"

Mon Mar  4 09:09:27 2019 rev:26 rq:680060 version:2.0.33

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-WebTest/python-WebTest.changes    
2019-02-14 14:11:04.592289572 +0100
+++ /work/SRC/openSUSE:Factory/.python-WebTest.new.28833/python-WebTest.changes 
2019-03-04 09:09:35.568715784 +0100
@@ -1,0 +2,8 @@
+Thu Feb 28 09:24:07 UTC 2019 - Tomáš Chvátal <[email protected]>
+
+- Update to 2.0.33:
+  * Fixed #210. Allow to reset select multiple with field.value = []
+  * Support for PYTHONOPTIMIZE=2, fix tests on PYTHONOPTIMIZE=1, 2
+  * Fixed #196. Fix deprecation warnings for collections to use 
collections.abc for Iterable on Python 3.
+
+-------------------------------------------------------------------

Old:
----
  WebTest-2.0.32.tar.gz

New:
----
  WebTest-2.0.33.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-WebTest.spec ++++++
--- /var/tmp/diff_new_pack.UYUGIp/_old  2019-03-04 09:09:36.992715545 +0100
+++ /var/tmp/diff_new_pack.UYUGIp/_new  2019-03-04 09:09:36.996715545 +0100
@@ -20,14 +20,13 @@
 %define oldpython python
 %bcond_without tests
 Name:           python-WebTest
-Version:        2.0.32
+Version:        2.0.33
 Release:        0
-Url:            http://webtest.pythonpaste.org/
 Summary:        Helper to test WSGI applications
 License:        MIT
 Group:          Development/Languages/Python
+URL:            http://webtest.pythonpaste.org/
 Source:         
https://files.pythonhosted.org/packages/source/W/WebTest/WebTest-%{version}.tar.gz
-BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 BuildRequires:  %{python_module PasteDeploy}
 BuildRequires:  %{python_module WSGIProxy2}
 BuildRequires:  %{python_module WebOb >= 1.2}
@@ -38,11 +37,6 @@
 BuildRequires:  %{python_module waitress >= 0.8.5}
 BuildRequires:  fdupes
 BuildRequires:  python-rpm-macros
-%if %{with tests}
-BuildRequires:  %{python_module coverage}
-BuildRequires:  %{python_module mock}
-BuildRequires:  %{python_module nose}
-%endif
 # Documentation build requirements:
 BuildRequires:  python3-Sphinx
 BuildRequires:  python3-pylons-sphinx-themes
@@ -50,11 +44,16 @@
 Requires:       python-beautifulsoup4
 Requires:       python-six
 Requires:       python-waitress >= 0.8.5
+BuildArch:      noarch
+%if %{with tests}
+BuildRequires:  %{python_module coverage}
+BuildRequires:  %{python_module mock}
+BuildRequires:  %{python_module nose}
+%endif
 %ifpython2
 Obsoletes:      %{oldpython}-webtest < %{version}
 Provides:       %{oldpython}-webtest = %{version}
 %endif
-BuildArch:      noarch
 %python_subpackages
 
 %description
@@ -91,13 +90,12 @@
 %endif
 
 %files %{python_files}
-%defattr(-,root,root,-)
-%doc CHANGELOG.rst README.rst docs/license.rst
+%license license.rst
+%doc CHANGELOG.rst README.rst
 %{python_sitelib}/webtest/
 %{python_sitelib}/WebTest-%{version}-py*.egg-info
 
 %files  -n %{name}-doc
-%defattr(-,root,root,-)
 %doc build/sphinx/html
 
 %changelog

++++++ WebTest-2.0.32.tar.gz -> WebTest-2.0.33.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/.github/ISSUE_TEMPLATE/bug_report.md 
new/WebTest-2.0.33/.github/ISSUE_TEMPLATE/bug_report.md
--- old/WebTest-2.0.32/.github/ISSUE_TEMPLATE/bug_report.md     1970-01-01 
01:00:00.000000000 +0100
+++ new/WebTest-2.0.33/.github/ISSUE_TEMPLATE/bug_report.md     2019-02-09 
19:18:31.000000000 +0100
@@ -0,0 +1,31 @@
+---
+name: Bug Report
+about: Create a report to help us improve
+
+---
+
+## Get Support
+To get help or technical support, see [Get 
Support](https://pylonsproject.org/community-support.html).
+
+## Bug Report
+
+Please [search the issue tracker](https://github.com/Pylons/webtest/issues) 
for similar issues before submitting a new issue.
+
+**Describe the bug**
+A clear and concise description of the bug.
+
+**To Reproduce**
+Steps to reproduce the behavior:
+1. Go to '...'
+2. Click on '....'
+3. Scroll down to '....'
+4. See error
+
+**Expected behavior**
+A clear and concise description of what you expected to happen.
+
+**Screenshots**
+If applicable, add screenshots to help explain the issue.
+
+**Additional context**
+Add any other context about the issue here.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/WebTest-2.0.32/.github/ISSUE_TEMPLATE/documentation.md 
new/WebTest-2.0.33/.github/ISSUE_TEMPLATE/documentation.md
--- old/WebTest-2.0.32/.github/ISSUE_TEMPLATE/documentation.md  1970-01-01 
01:00:00.000000000 +0100
+++ new/WebTest-2.0.33/.github/ISSUE_TEMPLATE/documentation.md  2019-02-09 
19:18:31.000000000 +0100
@@ -0,0 +1,29 @@
+---
+name: Documentation Suggestion
+about: Create an issue to improve our documentation
+
+---
+
+## Get Support
+To get help or technical support, see [Get 
Support](https://pylonsproject.org/community-support.html).
+
+## Documentation Suggestion
+
+Please [search the issue tracker](https://github.com/Pylons/webtest/issues) 
for similar issues before submitting a new issue.
+
+**Describe the issue**
+A clear and concise description of the issue.
+
+**Include references**
+1. Go to the URL '...'
+2. Click on '....'
+3. Scroll down to '....'
+
+**Describe the improvement**
+A clear and concise description of your suggestion.
+
+**Screenshots**
+If applicable, add screenshots to help explain the issue.
+
+**Additional context**
+Add any other context about the issue here.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/WebTest-2.0.32/.github/ISSUE_TEMPLATE/feature_request.md 
new/WebTest-2.0.33/.github/ISSUE_TEMPLATE/feature_request.md
--- old/WebTest-2.0.32/.github/ISSUE_TEMPLATE/feature_request.md        
1970-01-01 01:00:00.000000000 +0100
+++ new/WebTest-2.0.33/.github/ISSUE_TEMPLATE/feature_request.md        
2019-02-09 19:18:31.000000000 +0100
@@ -0,0 +1,24 @@
+---
+name: Feature Request
+about: Suggest an idea for this project
+
+---
+
+## Get Support
+To get help or technical support, see [Get 
Support](https://pylonsproject.org/community-support.html).
+
+## Feature Request
+
+Please [search the issue tracker](https://github.com/Pylons/webtest/issues) 
for similar issues before submitting a new issue.
+
+**Is your feature request related to an issue? Please describe.**
+A clear and concise description of the issue. Example: "I'm always frustrated 
when [...]".
+
+**Describe the solution you'd like**
+A clear and concise description of what you want to happen.
+
+**Describe alternatives you've considered**
+A clear and concise description of any alternative solutions or features 
you've considered.
+
+**Additional context**
+Add any other context or screenshots about the feature request here.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/CHANGELOG.rst 
new/WebTest-2.0.33/CHANGELOG.rst
--- old/WebTest-2.0.32/CHANGELOG.rst    2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/CHANGELOG.rst    2019-02-09 19:18:31.000000000 +0100
@@ -1,6 +1,17 @@
 News
 ====
 
+2.0.33 (2019-02-09)
+-------------------
+
+- Fixed #210. Allow to reset select multiple with `field.value = []`
+
+- Support for PYTHONOPTIMIZE=2, fix tests on PYTHONOPTIMIZE=1, 2
+
+- Fixed #196. Fix deprecation warnings for ``collections`` to use
+  ``collections.abc`` for ``Iterable`` on Python 3.
+
+
 2.0.32 (2018-10-05)
 -------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/MANIFEST.in 
new/WebTest-2.0.33/MANIFEST.in
--- old/WebTest-2.0.32/MANIFEST.in      2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/MANIFEST.in      2019-02-09 19:18:31.000000000 +0100
@@ -2,6 +2,8 @@
 prune docs/_build
 graft webtest
 graft tests
-include *.txt *.rst *.cfg *.ini .coveragerc
+graft .github
+include *.md *.txt *.rst *.cfg *.ini .coveragerc
 global-exclude *.pyc
+global-exclude *.swp
 global-exclude __pycache__
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/PKG-INFO new/WebTest-2.0.33/PKG-INFO
--- old/WebTest-2.0.32/PKG-INFO 2018-10-05 10:19:53.000000000 +0200
+++ new/WebTest-2.0.33/PKG-INFO 2019-02-09 19:18:31.000000000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.1
 Name: WebTest
-Version: 2.0.32
+Version: 2.0.33
 Summary: Helper to test WSGI applications
 Home-page: https://docs.pylonsproject.org/projects/webtest/en/latest/
 Author: Ian Bicking
@@ -35,5 +35,5 @@
 Classifier: Programming Language :: Python :: 3.5
 Classifier: Programming Language :: Python :: 3.6
 Classifier: Programming Language :: Python :: 3.7
-Provides-Extra: tests
 Provides-Extra: docs
+Provides-Extra: tests
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/WebTest.egg-info/PKG-INFO 
new/WebTest-2.0.33/WebTest.egg-info/PKG-INFO
--- old/WebTest-2.0.32/WebTest.egg-info/PKG-INFO        2018-10-05 
10:19:53.000000000 +0200
+++ new/WebTest-2.0.33/WebTest.egg-info/PKG-INFO        2019-02-09 
19:18:31.000000000 +0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.1
 Name: WebTest
-Version: 2.0.32
+Version: 2.0.33
 Summary: Helper to test WSGI applications
 Home-page: https://docs.pylonsproject.org/projects/webtest/en/latest/
 Author: Ian Bicking
@@ -35,5 +35,5 @@
 Classifier: Programming Language :: Python :: 3.5
 Classifier: Programming Language :: Python :: 3.6
 Classifier: Programming Language :: Python :: 3.7
-Provides-Extra: tests
 Provides-Extra: docs
+Provides-Extra: tests
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/WebTest.egg-info/SOURCES.txt 
new/WebTest-2.0.33/WebTest.egg-info/SOURCES.txt
--- old/WebTest-2.0.32/WebTest.egg-info/SOURCES.txt     2018-10-05 
10:19:53.000000000 +0200
+++ new/WebTest-2.0.33/WebTest.egg-info/SOURCES.txt     2019-02-09 
19:18:31.000000000 +0100
@@ -3,10 +3,15 @@
 MANIFEST.in
 README.rst
 RELEASING.rst
+contributing.md
+license.rst
 rtd.txt
 setup.cfg
 setup.py
 tox.ini
+.github/ISSUE_TEMPLATE/bug_report.md
+.github/ISSUE_TEMPLATE/documentation.md
+.github/ISSUE_TEMPLATE/feature_request.md
 WebTest.egg-info/PKG-INFO
 WebTest.egg-info/SOURCES.txt
 WebTest.egg-info/dependency_links.txt
@@ -23,7 +28,6 @@
 docs/form.html
 docs/forms.rst
 docs/index.rst
-docs/license.rst
 docs/testapp.rst
 docs/testresponse.rst
 docs/webtest.rst
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/contributing.md 
new/WebTest-2.0.33/contributing.md
--- old/WebTest-2.0.32/contributing.md  1970-01-01 01:00:00.000000000 +0100
+++ new/WebTest-2.0.33/contributing.md  2019-02-09 19:18:31.000000000 +0100
@@ -0,0 +1,22 @@
+# Contributing
+
+All projects under the Pylons Project, including this one, follow the 
guidelines established at [How to 
Contribute](https://pylonsproject.org/community-how-to-contribute.html), 
[Coding Style and 
Standards](https://pylonsproject.org/community-coding-style-standards.html), 
and [Pylons Project Documentation Style 
Guide](https://docs.pylonsproject.org/projects/docs-style-guide/).
+
+You can contribute to this project in several ways.
+
+*   [File an Issue on GitHub](https://github.com/Pylons/webtest/issues)
+*   Fork this project, create a new branch, commit your suggested change, and 
push to your fork on GitHub.
+    When ready, submit a pull request for consideration.
+    [GitHub Flow](https://guides.github.com/introduction/flow/index.html) 
describes the workflow process and why it's a good practice.
+*   Join the [IRC channel #pyramid on 
irc.freenode.net](https://webchat.freenode.net/?channels=pyramid).
+
+## Git Branches
+
+Git branches and their purpose and status at the time of this writing are 
listed below.
+
+*   [master](https://github.com/Pylons/webtest/) - The branch which should 
always be *deployable*. The default branch on GitHub.
+*   For development, create a new branch. If changes on your new branch are 
accepted, they will be merged into the master branch and deployed.
+
+## Prerequisites
+
+Follow the instructions in [README.rst](https://github.com/Pylons/webtest/) to 
install the tools needed to run the project.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/docs/changelog.rst 
new/WebTest-2.0.33/docs/changelog.rst
--- old/WebTest-2.0.32/docs/changelog.rst       2018-10-05 10:19:52.000000000 
+0200
+++ new/WebTest-2.0.33/docs/changelog.rst       2019-02-09 19:18:31.000000000 
+0100
@@ -1,6 +1,17 @@
 News
 ====
 
+2.0.33 (2019-02-09)
+-------------------
+
+- Fixed #210. Allow to reset select multiple with `field.value = []`
+
+- Support for PYTHONOPTIMIZE=2, fix tests on PYTHONOPTIMIZE=1, 2
+
+- Fixed #196. Fix deprecation warnings for ``collections`` to use
+  ``collections.abc`` for ``Iterable`` on Python 3.
+
+
 2.0.32 (2018-10-05)
 -------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/docs/index.rst 
new/WebTest-2.0.33/docs/index.rst
--- old/WebTest-2.0.32/docs/index.rst   2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/docs/index.rst   2019-02-09 19:18:31.000000000 +0100
@@ -128,4 +128,4 @@
 
 .. _license:
 
-.. include:: license.rst
+.. include:: ../license.rst
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/docs/license.rst 
new/WebTest-2.0.33/docs/license.rst
--- old/WebTest-2.0.32/docs/license.rst 2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/docs/license.rst 1970-01-01 01:00:00.000000000 +0100
@@ -1,23 +0,0 @@
-License
-=======
-
-Copyright (c) 2010 Ian Bicking and Contributors
-
-Permission is hereby granted, free of charge, to any person obtaining
-a copy of this software and associated documentation files (the
-"Software"), to deal in the Software without restriction, including
-without limitation the rights to use, copy, modify, merge, publish,
-distribute, sublicense, and/or sell copies of the Software, and to
-permit persons to whom the Software is furnished to do so, subject to
-the following conditions:
-
-The above copyright notice and this permission notice shall be
-included in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/license.rst 
new/WebTest-2.0.33/license.rst
--- old/WebTest-2.0.32/license.rst      1970-01-01 01:00:00.000000000 +0100
+++ new/WebTest-2.0.33/license.rst      2019-02-09 19:18:31.000000000 +0100
@@ -0,0 +1,23 @@
+License
+=======
+
+Copyright (c) 2010 Ian Bicking and Contributors
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/setup.py new/WebTest-2.0.33/setup.py
--- old/WebTest-2.0.32/setup.py 2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/setup.py 2019-02-09 19:18:31.000000000 +0100
@@ -5,7 +5,7 @@
 from setuptools import setup
 from setuptools import find_packages
 
-version = '2.0.32'
+version = '2.0.33'
 
 install_requires = [
     'six',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/tests/test_forms.py 
new/WebTest-2.0.33/tests/test_forms.py
--- old/WebTest-2.0.32/tests/test_forms.py      2018-10-05 10:19:52.000000000 
+0200
+++ new/WebTest-2.0.33/tests/test_forms.py      2019-02-09 19:18:31.000000000 
+0100
@@ -780,6 +780,13 @@
 
         multiple_form = res.forms["multiple_select_form"]
         self.assertEqual(multiple_form["multiple"].value, ["Nine", "Eleven"])
+        # reset with value
+        multiple_form["multiple"].value = []
+        self.assertIsNone(multiple_form["multiple"].value)
+        # re-set a value
+        multiple_form["multiple"].value = ['Nine']
+        assert multiple_form["multiple"].value == ['Nine']
+        # reset with force_value
         multiple_form["multiple"].force_value(None)
         self.assertIsNone(multiple_form["multiple"].value)
         display = multiple_form.submit("button")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/tests/test_lint.py 
new/WebTest-2.0.33/tests/test_lint.py
--- old/WebTest-2.0.32/tests/test_lint.py       2018-10-05 10:19:52.000000000 
+0200
+++ new/WebTest-2.0.33/tests/test_lint.py       2019-02-09 19:18:31.000000000 
+0100
@@ -1,6 +1,7 @@
 # -*- coding: utf-8 -*-
 from __future__ import unicode_literals
 
+import sys
 from six import PY3
 from six import StringIO
 from tests.compat import unittest
@@ -66,6 +67,7 @@
 
 class TestMiddleware(unittest.TestCase):
 
+    @unittest.skipIf(sys.flags.optimize > 0, "skip assert tests if optimize is 
enabled")
     def test_lint_too_few_args(self):
         linter = middleware(application)
         with self.assertRaisesRegexp(AssertionError, "Two arguments required"):
@@ -73,6 +75,7 @@
         with self.assertRaisesRegexp(AssertionError, "Two arguments required"):
             linter({})
 
+    @unittest.skipIf(sys.flags.optimize > 0, "skip assert tests if optimize is 
enabled")
     def test_lint_no_keyword_args(self):
         linter = middleware(application)
         with self.assertRaisesRegexp(AssertionError, "No keyword arguments "
@@ -286,6 +289,8 @@
 
 
 class TestWriteWrapper(unittest.TestCase):
+
+    @unittest.skipIf(sys.flags.optimize > 0, "skip assert tests if optimize is 
enabled")
     def test_wrong_type(self):
         write_wrapper = WriteWrapper(None)
         self.assertRaises(AssertionError, write_wrapper, 'not a binary')
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/tests/test_utils.py 
new/WebTest-2.0.33/tests/test_utils.py
--- old/WebTest-2.0.32/tests/test_utils.py      2018-10-05 10:19:52.000000000 
+0200
+++ new/WebTest-2.0.33/tests/test_utils.py      2019-02-09 19:18:31.000000000 
+0100
@@ -3,6 +3,8 @@
 from __future__ import unicode_literals
 import re
 import json
+import sys
+
 from .compat import unittest
 from webtest import utils
 
@@ -111,6 +113,7 @@
                                           'params': json.dumps({'a': 'b'}),
                                           'upload_files': None}))
 
+    @unittest.skipIf(sys.flags.optimize == 2, "no docstring if 
PYTHONOPTIMIZE=2")
     def test_json_method_doc(self):
         self.assertIn('FOO request', self.mock.foo_json.__doc__)
         self.assertIn('TestApp.foo', self.mock.foo_json.__doc__)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/webtest/compat.py 
new/WebTest-2.0.33/webtest/compat.py
--- old/WebTest-2.0.32/webtest/compat.py        2018-10-05 10:19:52.000000000 
+0200
+++ new/WebTest-2.0.33/webtest/compat.py        2019-02-09 19:18:31.000000000 
+0100
@@ -21,12 +21,14 @@
     from urllib.parse import splittype
     from urllib.parse import splithost
     import urllib.parse as urlparse
+    from collections.abc import Iterable  # noqa
 else:  # pragma: no cover
     from htmlentitydefs import name2codepoint  # noqa
     from urllib import splittype  # noqa
     from urllib import splithost  # noqa
     from urllib import urlencode  # noqa
     import urlparse  # noqa
+    from collections import Iterable  # noqa
 
 
 def print_stderr(value):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/webtest/forms.py 
new/WebTest-2.0.33/webtest/forms.py
--- old/WebTest-2.0.32/webtest/forms.py 2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/webtest/forms.py 2019-02-09 19:18:31.000000000 +0100
@@ -209,6 +209,10 @@
         return value
 
     def value__set(self, values):
+        if not values:
+            self._forced_values = None
+        elif self._forced_values is not NoValue:
+            self._forced_values = NoValue
         str_values = [utils.stringify(value) for value in values]
         self.selectedIndices = []
         for i, (option, checked, text) in enumerate(self.options):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/webtest/lint.py 
new/WebTest-2.0.33/webtest/lint.py
--- old/WebTest-2.0.32/webtest/lint.py  2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/webtest/lint.py  2019-02-09 19:18:31.000000000 +0100
@@ -116,7 +116,6 @@
 """
 from __future__ import unicode_literals
 
-import collections
 import re
 import warnings
 from six import PY3
@@ -124,6 +123,8 @@
 from six import string_types
 from six import text_type
 
+from webtest.compat import Iterable
+
 header_re = re.compile(r'^[a-zA-Z][a-zA-Z0-9\-_]*$')
 bad_header_value_re = re.compile(r'[\000-\037]')
 
@@ -198,8 +199,10 @@
         environ['wsgi.errors'] = ErrorWrapper(environ['wsgi.errors'])
 
         iterator = application(environ, start_response_wrapper)
-        assert isinstance(iterator, collections.Iterable), (
-            "The application must return an iterator, if only an empty list")
+        if not isinstance(iterator, Iterable):
+            raise AssertionError(
+                "The application must return an iterator, if only an empty 
list"
+            )
 
         check_iterator(iterator)
 
@@ -240,7 +243,7 @@
             yield line
 
     def close(self):
-        assert 0, "input.close() must not be called"
+        raise AssertionError("input.close() must not be called")
 
     def seek(self, *a, **kw):
         return self.input.seek(*a, **kw)
@@ -264,7 +267,7 @@
             self.write(line)
 
     def close(self):
-        assert 0, "errors.close() must not be called"
+        raise AssertionError("errors.close() must not be called")
 
 
 class WriteWrapper(object):
@@ -315,21 +318,25 @@
 
 
 def check_environ(environ):
-    assert type(environ) is dict, (
-        "Environment is not of the right type: %r (environment: %r)"
-        % (type(environ), environ))
+    if type(environ) is not dict:
+        raise AssertionError(
+            "Environment is not of the right type: %r (environment: %r)"
+            % (type(environ), environ)
+        )
 
     for key in ['REQUEST_METHOD', 'SERVER_NAME', 'SERVER_PORT',
                 'wsgi.version', 'wsgi.input', 'wsgi.errors',
                 'wsgi.multithread', 'wsgi.multiprocess',
                 'wsgi.run_once']:
-        assert key in environ, (
-            "Environment missing required key: %r" % key)
+        if key not in environ:
+            raise AssertionError("Environment missing required key: %r" % key)
 
     for key in ['HTTP_CONTENT_TYPE', 'HTTP_CONTENT_LENGTH']:
-        assert key not in environ, (
-            "Environment should not have the key: %s "
-            "(use %s instead)" % (key, key[5:]))
+        if key in environ:
+            raise AssertionError(
+                "Environment should not have the key: %s "
+                "(use %s instead)" % (key, key[5:])
+            )
 
     if 'QUERY_STRING' not in environ:
         warnings.warn(
@@ -342,14 +349,21 @@
         if '.' in key:
             # Extension, we don't care about its type
             continue
-        assert type(environ[key]) in METADATA_TYPE, (
-            "Environmental variable %s is not a string: %r (value: %r)"
-            % (key, type(environ[key]), environ[key]))
-
-    assert type(environ['wsgi.version']) is tuple, (
-        "wsgi.version should be a tuple (%r)" % environ['wsgi.version'])
-    assert environ['wsgi.url_scheme'] in ('http', 'https'), (
-        "wsgi.url_scheme unknown: %r" % environ['wsgi.url_scheme'])
+        if type(environ[key]) not in METADATA_TYPE:
+            raise AssertionError(
+                "Environmental variable %s is not a string: %r (value: %r)"
+                % (key, type(environ[key]), environ[key])
+            )
+
+    if type(environ['wsgi.version']) is not tuple:
+        raise AssertionError(
+            "wsgi.version should be a tuple (%r)" % environ['wsgi.version']
+        )
+
+    if environ['wsgi.url_scheme'] not in ('http', 'https'):
+        raise AssertionError(
+            "wsgi.url_scheme unknown: %r" % environ['wsgi.url_scheme']
+        )
 
     check_input(environ['wsgi.input'])
     check_errors(environ['wsgi.errors'])
@@ -360,62 +374,89 @@
             "Unknown REQUEST_METHOD: %r" % environ['REQUEST_METHOD'],
             WSGIWarning)
 
-    assert (not environ.get('SCRIPT_NAME')
-            or environ['SCRIPT_NAME'].startswith(SLASH)), (
-        "SCRIPT_NAME doesn't start with /: %r" % environ['SCRIPT_NAME'])
-    assert (not environ.get('PATH_INFO')
-            or environ['PATH_INFO'].startswith(SLASH)), (
-        "PATH_INFO doesn't start with /: %r" % environ['PATH_INFO'])
+    if environ.get('SCRIPT_NAME') and not 
environ['SCRIPT_NAME'].startswith(SLASH):
+        raise AssertionError(
+            "SCRIPT_NAME doesn't start with /: %r" % environ['SCRIPT_NAME']
+        )
+
+    if environ.get('PATH_INFO') and not environ['PATH_INFO'].startswith(SLASH):
+        raise AssertionError(
+            "PATH_INFO doesn't start with /: %r" % environ['PATH_INFO']
+        )
+
     if environ.get('CONTENT_LENGTH'):
-        assert int(environ['CONTENT_LENGTH']) >= 0, (
-            "Invalid CONTENT_LENGTH: %r" % environ['CONTENT_LENGTH'])
+        if int(environ['CONTENT_LENGTH']) < 0:
+            raise AssertionError(
+                "Invalid CONTENT_LENGTH: %r" % environ['CONTENT_LENGTH']
+            )
 
     if not environ.get('SCRIPT_NAME'):
-        assert 'PATH_INFO' in environ, (
-            "One of SCRIPT_NAME or PATH_INFO are required (PATH_INFO "
-            "should at least be '/' if SCRIPT_NAME is empty)")
-    assert environ.get('SCRIPT_NAME') != SLASH, (
-        "SCRIPT_NAME cannot be '/'; it should instead be '', and "
-        "PATH_INFO should be '/'")
+        if 'PATH_INFO' not in environ:
+            raise AssertionError(
+                "One of SCRIPT_NAME or PATH_INFO are required (PATH_INFO "
+                "should at least be '/' if SCRIPT_NAME is empty)"
+            )
+
+    if environ.get('SCRIPT_NAME') == SLASH:
+        raise AssertionError(
+            "SCRIPT_NAME cannot be '/'; it should instead be '', and "
+            "PATH_INFO should be '/'"
+        )
 
 
 def check_input(wsgi_input):
     for attr in ['read', 'readline', 'readlines', '__iter__']:
-        assert hasattr(wsgi_input, attr), (
-            "wsgi.input (%r) doesn't have the attribute %s"
-            % (wsgi_input, attr))
+        if not hasattr(wsgi_input, attr):
+            raise AssertionError(
+                "wsgi.input (%r) doesn't have the attribute %s"
+                % (wsgi_input, attr)
+            )
 
 
 def check_errors(wsgi_errors):
     for attr in ['flush', 'write', 'writelines']:
-        assert hasattr(wsgi_errors, attr), (
-            "wsgi.errors (%r) doesn't have the attribute %s"
-            % (wsgi_errors, attr))
+        if not hasattr(wsgi_errors, attr):
+            raise AssertionError(
+                "wsgi.errors (%r) doesn't have the attribute %s"
+                % (wsgi_errors, attr)
+            )
 
 
 def check_status(status):
-    assert type(status) in METADATA_TYPE, (
-        "Status must be a %s (not %r)" % (METADATA_TYPE, status))
+    if type(status) not in METADATA_TYPE:
+        raise AssertionError("Status must be a %s (not %r)" % (METADATA_TYPE, 
status))
+
     status = to_string(status)
-    assert len(status) > 5, (
-        "The status string (%r) should be a three-digit "
-        "integer followed by a single space and a status explanation"
-        ) % status
-    assert status[:3].isdigit(), (
-        "The status string (%r) should start with"
-        "three digits") % status
+
+    if len(status) <= 5:
+        raise AssertionError(
+            "The status string (%r) should be a three-digit "
+            "integer followed by a single space and a status explanation" % 
status
+        )
+
+    if not status[:3].isdigit():
+        raise AssertionError(
+            "The status string (%r) should start with three digits" % status
+        )
 
     status_int = int(status[:3])
-    assert status_int >= 100, (
-        "The status code must be greater or equal than "
-        "100 (got %d)") % status_int
-    assert status[3] == ' ', (
-        "The status string (%r) should start with three"
-        "digits and a space (4th characters is not a space here)") % status
+
+    if status_int < 100:
+        raise AssertionError(
+            "The status code must be greater or equal than 100 (got %d)" % 
status_int
+        )
+
+    if status[3] != ' ':
+        raise AssertionError(
+            "The status string (%r) should start with three"
+            "digits and a space (4th characters is not a space here)" % status
+        )
 
 
 def _assert_latin1_str(string, message):
-    assert type(string) is str, message
+    if type(string) is not str:
+        raise AssertionError(message)
+
     if type(string) is text_type:
         try:
             string.encode('latin1')
@@ -425,13 +466,18 @@
 
 
 def check_headers(headers):
-    assert type(headers) is list, (
-        "Headers (%r) must be of type list: %r"
-        % (headers, type(headers)))
+    if type(headers) is not list:
+        raise AssertionError(
+            "Headers (%r) must be of type list: %r" % (headers, type(headers))
+        )
+
     for item in headers:
-        assert type(item) is tuple, (
-            "Individual headers (%r) must be of type tuple: %r"
-            % (item, type(item)))
+        if type(item) is not tuple:
+            raise AssertionError(
+                "Individual headers (%r) must be of type tuple: %r"
+                % (item, type(item))
+            )
+
         assert len(item) == 2
         name, value = item
         _assert_latin1_str(
@@ -440,24 +486,37 @@
             "(not Py2 unicode or Py3 bytes type). "
             "%r is not a valid latin1 string" % (name,)
         )
-        assert name.lower() != 'status', (
-            "The Status header cannot be used; it conflicts with CGI "
-            "script, and HTTP status is not given through headers "
-            "(value: %r)." % value)
-        assert '\n' not in name and ':' not in name, (
-            "Header names may not contain ':' or '\\n': %r" % name)
-        assert header_re.search(name), "Bad header name: %r" % name
-        assert not name.endswith('-') and not name.endswith('_'), (
-            "Names may not end in '-' or '_': %r" % name)
+
+        if name.lower() == 'status':
+            raise AssertionError(
+                "The Status header cannot be used; it conflicts with CGI "
+                "script, and HTTP status is not given through headers "
+                "(value: %r)." % value
+            )
+
+        if '\n' in name or ':' in name:
+            raise AssertionError(
+                "Header names may not contain ':' or '\\n': %r" % name
+            )
+
+        if not header_re.search(name):
+            raise AssertionError("Bad header name: %r" % name)
+
+        if name.endswith('-') or name.endswith('_'):
+            raise AssertionError("Names may not end in '-' or '_': %r" % name)
+
         _assert_latin1_str(
             value,
             "Header values must be latin1 string "
             "(not Py2 unicode or Py3 bytes type)."
             "%r is not a valid latin1 string" % (value,)
         )
-        assert not bad_header_value_re.search(value), (
-            "Bad header value: %r (bad char: %r)"
-            % (str_value, bad_header_value_re.search(value).group(0)))
+
+        if bad_header_value_re.search(value):
+            raise AssertionError(
+                "Bad header value: %r (bad char: %r)"
+                % (str_value, bad_header_value_re.search(value).group(0))
+            )
 
 
 def check_content_type(status, headers):
@@ -481,15 +540,22 @@
                               WSGIWarning)
                 return
             else:
-                assert 0, (("Content-Type header found in a %s response, "
-                            "which must not return content.") % code)
+                raise AssertionError(
+                    "Content-Type header found in a %s response, "
+                    "which must not return content." % code
+                )
+
     if code not in NO_MESSAGE_BODY and length is not None and length > 0:
-        assert 0, "No Content-Type header found in headers (%s)" % headers
+        raise AssertionError(
+            "No Content-Type header found in headers (%s)" % headers
+        )
 
 
 def check_exc_info(exc_info):
-    assert exc_info is None or type(exc_info) is tuple, (
-        "exc_info (%r) is not a tuple: %r" % (exc_info, type(exc_info)))
+    if exc_info is not None and type(exc_info) is not tuple:
+        raise AssertionError(
+            "exc_info (%r) is not a tuple: %r" % (exc_info, type(exc_info))
+        )
     # More exc_info checks?
 
 
@@ -498,8 +564,11 @@
     # Technically a bytes (str for py2.x) is legal, which is why it's a
     # really bad idea, because it may cause the response to be returned
     # character-by-character
-    assert not isinstance(iterator, valid_type), (
-        "You should not return a bytes as your application iterator, "
-        "instead return a single-item list containing that string.")
+
+    if isinstance(iterator, valid_type):
+        raise AssertionError(
+            "You should not return a bytes as your application iterator, "
+            "instead return a single-item list containing that string."
+        )
 
 __all__ = ['middleware']
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/webtest/response.py 
new/WebTest-2.0.33/webtest/response.py
--- old/WebTest-2.0.32/webtest/response.py      2018-10-05 10:19:52.000000000 
+0200
+++ new/WebTest-2.0.33/webtest/response.py      2019-02-09 19:18:31.000000000 
+0100
@@ -96,9 +96,10 @@
         arguments are passed to :class:`webtest.app.TestApp.get`. Returns
         another :class:`TestResponse` object.
         """
-        assert 300 <= self.status_int < 400, (
-            "You can only follow redirect responses (not %s)"
-            % self.status)
+        if not (300 <= self.status_int < 400):
+            raise AssertionError(
+                "You can only follow redirect responses (not %s)" % self.status
+            )
         return self._follow(**kw)
 
     def maybe_follow(self, **kw):
@@ -114,7 +115,9 @@
             response = response._follow(**kw)
             remaining_redirects -= 1
 
-        assert remaining_redirects > 0, "redirects chain looks infinite"
+        if remaining_redirects <= 0:
+            raise AssertionError("redirects chain looks infinite")
+
         return response
 
     def click(self, description=None, linkid=None, href=None,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/WebTest-2.0.32/webtest/utils.py 
new/WebTest-2.0.33/webtest/utils.py
--- old/WebTest-2.0.32/webtest/utils.py 2018-10-05 10:19:52.000000000 +0200
+++ new/WebTest-2.0.33/webtest/utils.py 2019-02-09 19:18:31.000000000 +0100
@@ -36,7 +36,12 @@
         return self._gen_request(method, url, **kw)
 
     subst = dict(lmethod=method.lower(), method=method)
-    wrapper.__doc__ = json_method.__doc__ % subst
+
+    try:
+        wrapper.__doc__ = json_method.__doc__ % subst
+    except TypeError:
+        pass
+
     wrapper.__name__ = str('%(lmethod)s_json' % subst)
 
     return wrapper


Reply via email to