Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-wsgi_intercept for 
openSUSE:Factory checked in at 2022-10-12 18:24:30
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-wsgi_intercept (Old)
 and      /work/SRC/openSUSE:Factory/.python-wsgi_intercept.new.2275 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-wsgi_intercept"

Wed Oct 12 18:24:30 2022 rev:26 rq:1009883 version:1.10.0

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-wsgi_intercept/python-wsgi_intercept.changes  
    2020-03-16 10:18:21.983587922 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-wsgi_intercept.new.2275/python-wsgi_intercept.changes
    2022-10-12 18:26:07.185878487 +0200
@@ -1,0 +2,6 @@
+Tue Oct 11 17:19:22 UTC 2022 - Yogalakshmi Arunachalam <yarunacha...@suse.com>
+
+- Update to version 1.10.0 
+  * No upstream changelog
+
+-------------------------------------------------------------------

Old:
----
  wsgi_intercept-1.9.2.tar.gz

New:
----
  wsgi_intercept-1.10.0.tar.gz

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

Other differences:
------------------
++++++ python-wsgi_intercept.spec ++++++
--- /var/tmp/diff_new_pack.0E3ea8/_old  2022-10-12 18:26:08.389881137 +0200
+++ /var/tmp/diff_new_pack.0E3ea8/_new  2022-10-12 18:26:08.393881146 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package python-wsgi_intercept
 #
-# Copyright (c) 2020 SUSE LLC
+# Copyright (c) 2022 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -18,7 +18,7 @@
 
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 Name:           python-wsgi_intercept
-Version:        1.9.2
+Version:        1.10.0
 Release:        0
 Summary:        Library for installing a WSGI application in place of a real 
URI for testing
 License:        MIT

++++++ wsgi_intercept-1.9.2.tar.gz -> wsgi_intercept-1.10.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/wsgi_intercept-1.9.2/PKG-INFO 
new/wsgi_intercept-1.10.0/PKG-INFO
--- old/wsgi_intercept-1.9.2/PKG-INFO   2020-02-05 12:15:55.000000000 +0100
+++ new/wsgi_intercept-1.10.0/PKG-INFO  2022-05-16 13:43:18.667807000 +0200
@@ -1,151 +1,11 @@
 Metadata-Version: 2.1
 Name: wsgi_intercept
-Version: 1.9.2
+Version: 1.10.0
 Summary: wsgi_intercept installs a WSGI application in place of a real URI for 
testing.
 Home-page: http://pypi.python.org/pypi/wsgi_intercept
 Author: Titus Brown, Kumar McMillan, Chris Dent, Sasha Hart
 Author-email: cd...@peermore.com
 License: MIT License
-Description: Installs a WSGI application in place of a real host for testing.
-        
-        Introduction
-        ============
-        
-        Testing a WSGI application sometimes involves starting a server at a
-        local host and port, then pointing your test code to that address.
-        Instead, this library lets you intercept calls to any specific 
host/port
-        combination and redirect them into a `WSGI application`_ importable by
-        your test program. Thus, you can avoid spawning multiple processes or
-        threads to test your Web app.
-        
-        Supported Libaries
-        ==================
-        
-        ``wsgi_intercept`` works with a variety of HTTP clients in Python 2.7,
-        3.5 and beyond, and in pypy.
-        
-        * urllib2
-        * urllib.request
-        * httplib
-        * http.client
-        * httplib2
-        * requests
-        * urllib3
-        
-        How Does It Work?
-        =================
-        
-        ``wsgi_intercept`` works by replacing ``httplib.HTTPConnection`` with a
-        subclass, ``wsgi_intercept.WSGI_HTTPConnection``. This class then
-        redirects specific server/port combinations into a WSGI application by
-        emulating a socket. If no intercept is registered for the host and port
-        requested, those requests are passed on to the standard handler.
-        
-        The easiest way to use an intercept is to import an appropriate 
subclass
-        of ``~wsgi_intercept.interceptor.Interceptor`` and use that as a
-        context manager over web requests that use the library associated with
-        the subclass. For example::
-        
-            import httplib2
-            from wsgi_intercept.interceptor import Httplib2Interceptor
-            from mywsgiapp import app
-        
-            def load_app():
-                return app
-        
-            http = httplib2.Http()
-            with Httplib2Interceptor(load_app, host='example.com', port=80) as 
url:
-                response, content = http.request('%s%s' % (url, '/path'))
-                assert response.status == 200
-        
-        The interceptor class may aslo be used directly to install intercepts.
-        See the module documentation for more information.
-        
-        Older versions required that the functions ``add_wsgi_intercept(host,
-        port, app_create_fn, script_name='')`` and 
``remove_wsgi_intercept(host,port)``
-        be used to specify which URLs should be redirected into what 
applications.
-        These methods are still available, but the ``Interceptor`` classes are 
likely
-        easier to use for most use cases.
-        
-        .. note:: ``app_create_fn`` is a *function object* returning a WSGI
-                  application; ``script_name`` becomes ``SCRIPT_NAME`` in the 
WSGI
-                  app's environment, if set.
-        
-        .. note:: If ``http_proxy`` or ``https_proxy`` is set in the 
environment
-                  this can cause difficulties with some of the intercepted 
libraries.
-                  If requests or urllib is being used, these will raise an 
exception
-                  if one of those variables is set.
-        
-        .. note:: If ``wsgi_intercept.STRICT_RESPONSE_HEADERS`` is set to 
``True``
-                  then response headers sent by an application will be checked 
to
-                  make sure they are of the type ``str`` native to the version 
of
-                  Python, as required by pep 3333. The default is ``False`` (to
-                  preserve backwards compatibility)
-        
-        
-        Install
-        =======
-        
-        ::
-        
-            pip install -U wsgi_intercept
-        
-        Packages Intercepted
-        ====================
-        
-        Unfortunately each of the HTTP client libraries use their own specific
-        mechanism for making HTTP call-outs, so individual implementations are
-        needed. At this time there are implementations for ``httplib2``,
-        ``urllib3`` and ``requests`` in both Python 2 and 3, ``urllib2`` and
-        ``httplib`` in Python 2 and ``urllib.request`` and ``http.client``
-        in Python 3.
-        
-        If you are using Python 2 and need support for a different HTTP
-        client, require a version of ``wsgi_intercept<0.6``. Earlier versions
-        include support for ``webtest``, ``webunit`` and ``zope.testbrowser``.
-        
-        The best way to figure out how to use interception is to inspect
-        `the tests`_. More comprehensive documentation available upon
-        request.
-        
-        .. _the tests: https://github.com/cdent/wsgi-intercept/tree/master/test
-        
-        
-        History
-        =======
-        
-        Pursuant to Ian Bicking's `"best Web testing framework"`_ post, Titus
-        Brown put together an `in-process HTTP-to-WSGI interception mechanism`_
-        for his own Web testing system, twill. Because the mechanism is pretty
-        generic -- it works at the httplib level -- Titus decided to try adding
-        it into all of the *other* Python Web testing frameworks.
-        
-        The Python 2 version of wsgi-intercept was the result. Kumar McMillan
-        later took over maintenance.
-        
-        The current version is tested with Python 2.7, 3.5-3.8, and pypy and 
pypy3.
-        It was assembled by `Chris Dent`_. Testing and documentation 
improvements
-        from `Sasha Hart`_.
-        
-        .. _"best Web testing framework":
-             
http://blog.ianbicking.org/best-of-the-web-app-test-frameworks.html
-        .. _in-process HTTP-to-WSGI interception mechanism:
-             http://www.advogato.org/person/titus/diary.html?start=119
-        .. _WSGI application: http://www.python.org/peps/pep-3333.html
-        .. _Chris Dent: https://github.com/cdent
-        .. _Sasha Hart: https://github.com/sashahart
-        
-        Project Home
-        ============
-        
-        This project lives on `GitHub`_. Please submit all bugs, patches,
-        failing tests, et cetera using the Issue Tracker.
-        
-        Additional documentation is available on `Read The Docs`_.
-        
-        .. _GitHub: http://github.com/cdent/wsgi-intercept
-        .. _Read The Docs: http://wsgi-intercept.readthedocs.org/en/latest/
-        
 Platform: UNKNOWN
 Classifier: Environment :: Web Environment
 Classifier: Intended Audience :: Developers
@@ -162,3 +22,146 @@
 Classifier: Topic :: Software Development :: Testing
 Provides-Extra: testing
 Provides-Extra: docs
+License-File: LICENSE
+
+Installs a WSGI application in place of a real host for testing.
+
+Introduction
+============
+
+Testing a WSGI application sometimes involves starting a server at a
+local host and port, then pointing your test code to that address.
+Instead, this library lets you intercept calls to any specific host/port
+combination and redirect them into a `WSGI application`_ importable by
+your test program. Thus, you can avoid spawning multiple processes or
+threads to test your Web app.
+
+Supported Libaries
+==================
+
+``wsgi_intercept`` works with a variety of HTTP clients in Python 2.7,
+3.5 and beyond, and in pypy.
+
+* urllib2
+* urllib.request
+* httplib
+* http.client
+* httplib2
+* requests
+* urllib3
+
+How Does It Work?
+=================
+
+``wsgi_intercept`` works by replacing ``httplib.HTTPConnection`` with a
+subclass, ``wsgi_intercept.WSGI_HTTPConnection``. This class then
+redirects specific server/port combinations into a WSGI application by
+emulating a socket. If no intercept is registered for the host and port
+requested, those requests are passed on to the standard handler.
+
+The easiest way to use an intercept is to import an appropriate subclass
+of ``~wsgi_intercept.interceptor.Interceptor`` and use that as a
+context manager over web requests that use the library associated with
+the subclass. For example::
+
+    import httplib2
+    from wsgi_intercept.interceptor import Httplib2Interceptor
+    from mywsgiapp import app
+
+    def load_app():
+        return app
+
+    http = httplib2.Http()
+    with Httplib2Interceptor(load_app, host='example.com', port=80) as url:
+        response, content = http.request('%s%s' % (url, '/path'))
+        assert response.status == 200
+
+The interceptor class may aslo be used directly to install intercepts.
+See the module documentation for more information.
+
+Older versions required that the functions ``add_wsgi_intercept(host,
+port, app_create_fn, script_name='')`` and ``remove_wsgi_intercept(host,port)``
+be used to specify which URLs should be redirected into what applications.
+These methods are still available, but the ``Interceptor`` classes are likely
+easier to use for most use cases.
+
+.. note:: ``app_create_fn`` is a *function object* returning a WSGI
+          application; ``script_name`` becomes ``SCRIPT_NAME`` in the WSGI
+          app's environment, if set.
+
+.. note:: If ``http_proxy`` or ``https_proxy`` is set in the environment
+          this can cause difficulties with some of the intercepted libraries.
+          If requests or urllib is being used, these will raise an exception
+          if one of those variables is set.
+
+.. note:: If ``wsgi_intercept.STRICT_RESPONSE_HEADERS`` is set to ``True``
+          then response headers sent by an application will be checked to
+          make sure they are of the type ``str`` native to the version of
+          Python, as required by pep 3333. The default is ``False`` (to
+          preserve backwards compatibility)
+
+
+Install
+=======
+
+::
+
+    pip install -U wsgi_intercept
+
+Packages Intercepted
+====================
+
+Unfortunately each of the HTTP client libraries use their own specific
+mechanism for making HTTP call-outs, so individual implementations are
+needed. At this time there are implementations for ``httplib2``,
+``urllib3`` and ``requests`` in both Python 2 and 3, ``urllib2`` and
+``httplib`` in Python 2 and ``urllib.request`` and ``http.client``
+in Python 3.
+
+If you are using Python 2 and need support for a different HTTP
+client, require a version of ``wsgi_intercept<0.6``. Earlier versions
+include support for ``webtest``, ``webunit`` and ``zope.testbrowser``.
+
+The best way to figure out how to use interception is to inspect
+`the tests`_. More comprehensive documentation available upon
+request.
+
+.. _the tests: https://github.com/cdent/wsgi-intercept/tree/master/test
+
+
+History
+=======
+
+Pursuant to Ian Bicking's `"best Web testing framework"`_ post, Titus
+Brown put together an `in-process HTTP-to-WSGI interception mechanism`_
+for his own Web testing system, twill. Because the mechanism is pretty
+generic -- it works at the httplib level -- Titus decided to try adding
+it into all of the *other* Python Web testing frameworks.
+
+The Python 2 version of wsgi-intercept was the result. Kumar McMillan
+later took over maintenance.
+
+The current version is tested with Python 2.7, 3.5-3.8, and pypy and pypy3.
+It was assembled by `Chris Dent`_. Testing and documentation improvements
+from `Sasha Hart`_.
+
+.. _"best Web testing framework":
+     http://blog.ianbicking.org/best-of-the-web-app-test-frameworks.html
+.. _in-process HTTP-to-WSGI interception mechanism:
+     http://www.advogato.org/person/titus/diary.html?start=119
+.. _WSGI application: http://www.python.org/peps/pep-3333.html
+.. _Chris Dent: https://github.com/cdent
+.. _Sasha Hart: https://github.com/sashahart
+
+Project Home
+============
+
+This project lives on `GitHub`_. Please submit all bugs, patches,
+failing tests, et cetera using the Issue Tracker.
+
+Additional documentation is available on `Read The Docs`_.
+
+.. _GitHub: http://github.com/cdent/wsgi-intercept
+.. _Read The Docs: http://wsgi-intercept.readthedocs.org/en/latest/
+
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/wsgi_intercept-1.9.2/setup.py 
new/wsgi_intercept-1.10.0/setup.py
--- old/wsgi_intercept-1.9.2/setup.py   2020-02-05 12:13:22.000000000 +0100
+++ new/wsgi_intercept-1.10.0/setup.py  2022-05-16 13:39:31.000000000 +0200
@@ -1,7 +1,7 @@
 
 from setuptools import setup, find_packages
 
-VERSION = '1.9.2'
+VERSION = '1.10.0'
 
 CLASSIFIERS = """
 Environment :: Web Environment
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/wsgi_intercept-1.9.2/wsgi_intercept/__init__.py 
new/wsgi_intercept-1.10.0/wsgi_intercept/__init__.py
--- old/wsgi_intercept-1.9.2/wsgi_intercept/__init__.py 2020-02-05 
12:08:46.000000000 +0100
+++ new/wsgi_intercept-1.10.0/wsgi_intercept/__init__.py        2022-05-16 
13:39:02.000000000 +0200
@@ -260,7 +260,7 @@
         else:
             h = k.upper()
             h = h.replace(b'-', b'_')
-            environ['HTTP_' + h.decode('ISO-8859-1')] = v
+            environ['HTTP_' + str(h.decode('ISO-8859-1'))] = v
 
         if debuglevel >= 2:
             print('HEADER:', k, v)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/wsgi_intercept-1.9.2/wsgi_intercept/_urllib3.py 
new/wsgi_intercept-1.10.0/wsgi_intercept/_urllib3.py
--- old/wsgi_intercept-1.9.2/wsgi_intercept/_urllib3.py 2020-02-05 
12:08:46.000000000 +0100
+++ new/wsgi_intercept-1.10.0/wsgi_intercept/_urllib3.py        2022-01-13 
15:31:38.000000000 +0100
@@ -17,6 +17,7 @@
             if 'strict' in kwargs and sys.version_info > (3, 0):
                 kwargs.pop('strict')
             kwargs.pop('socket_options', None)
+            kwargs.pop('server_hostname', None)
             WSGI_HTTPConnection.__init__(self, *args, **kwargs)
             HTTPConnection.__init__(self, *args, **kwargs)
 
@@ -28,6 +29,7 @@
                 kwargs.pop('strict')
             kwargs.pop('socket_options', None)
             kwargs.pop('key_password', None)
+            kwargs.pop('server_hostname', None)
             WSGI_HTTPSConnection.__init__(self, *args, **kwargs)
             HTTPSConnection.__init__(self, *args, **kwargs)
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/wsgi_intercept-1.9.2/wsgi_intercept/tests/test_wsgiref.py 
new/wsgi_intercept-1.10.0/wsgi_intercept/tests/test_wsgiref.py
--- old/wsgi_intercept-1.9.2/wsgi_intercept/tests/test_wsgiref.py       
1970-01-01 01:00:00.000000000 +0100
+++ new/wsgi_intercept-1.10.0/wsgi_intercept/tests/test_wsgiref.py      
2022-05-16 13:39:02.000000000 +0200
@@ -0,0 +1,23 @@
+import requests
+import wsgiref.simple_server
+
+from wsgi_intercept.interceptor import RequestsInterceptor
+
+
+def load_app():
+    return wsgiref.simple_server.demo_app
+
+
+def test_wsgiref():
+    """General test that the wsgiref server behaves.
+
+    This mostly confirms that environ handling is correct in both
+    python2 and 3.
+    """
+
+    try:
+        with RequestsInterceptor(load_app, host='www.example.net', port=80):
+            r = requests.get('http://www.example.net')
+            print(r.text)
+    except Exception as exc:
+        assert False, 'wsgi ref server raised exception: %s' % exc
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/wsgi_intercept-1.9.2/wsgi_intercept.egg-info/PKG-INFO 
new/wsgi_intercept-1.10.0/wsgi_intercept.egg-info/PKG-INFO
--- old/wsgi_intercept-1.9.2/wsgi_intercept.egg-info/PKG-INFO   2020-02-05 
12:15:55.000000000 +0100
+++ new/wsgi_intercept-1.10.0/wsgi_intercept.egg-info/PKG-INFO  2022-05-16 
13:43:18.000000000 +0200
@@ -1,151 +1,11 @@
 Metadata-Version: 2.1
 Name: wsgi-intercept
-Version: 1.9.2
+Version: 1.10.0
 Summary: wsgi_intercept installs a WSGI application in place of a real URI for 
testing.
 Home-page: http://pypi.python.org/pypi/wsgi_intercept
 Author: Titus Brown, Kumar McMillan, Chris Dent, Sasha Hart
 Author-email: cd...@peermore.com
 License: MIT License
-Description: Installs a WSGI application in place of a real host for testing.
-        
-        Introduction
-        ============
-        
-        Testing a WSGI application sometimes involves starting a server at a
-        local host and port, then pointing your test code to that address.
-        Instead, this library lets you intercept calls to any specific 
host/port
-        combination and redirect them into a `WSGI application`_ importable by
-        your test program. Thus, you can avoid spawning multiple processes or
-        threads to test your Web app.
-        
-        Supported Libaries
-        ==================
-        
-        ``wsgi_intercept`` works with a variety of HTTP clients in Python 2.7,
-        3.5 and beyond, and in pypy.
-        
-        * urllib2
-        * urllib.request
-        * httplib
-        * http.client
-        * httplib2
-        * requests
-        * urllib3
-        
-        How Does It Work?
-        =================
-        
-        ``wsgi_intercept`` works by replacing ``httplib.HTTPConnection`` with a
-        subclass, ``wsgi_intercept.WSGI_HTTPConnection``. This class then
-        redirects specific server/port combinations into a WSGI application by
-        emulating a socket. If no intercept is registered for the host and port
-        requested, those requests are passed on to the standard handler.
-        
-        The easiest way to use an intercept is to import an appropriate 
subclass
-        of ``~wsgi_intercept.interceptor.Interceptor`` and use that as a
-        context manager over web requests that use the library associated with
-        the subclass. For example::
-        
-            import httplib2
-            from wsgi_intercept.interceptor import Httplib2Interceptor
-            from mywsgiapp import app
-        
-            def load_app():
-                return app
-        
-            http = httplib2.Http()
-            with Httplib2Interceptor(load_app, host='example.com', port=80) as 
url:
-                response, content = http.request('%s%s' % (url, '/path'))
-                assert response.status == 200
-        
-        The interceptor class may aslo be used directly to install intercepts.
-        See the module documentation for more information.
-        
-        Older versions required that the functions ``add_wsgi_intercept(host,
-        port, app_create_fn, script_name='')`` and 
``remove_wsgi_intercept(host,port)``
-        be used to specify which URLs should be redirected into what 
applications.
-        These methods are still available, but the ``Interceptor`` classes are 
likely
-        easier to use for most use cases.
-        
-        .. note:: ``app_create_fn`` is a *function object* returning a WSGI
-                  application; ``script_name`` becomes ``SCRIPT_NAME`` in the 
WSGI
-                  app's environment, if set.
-        
-        .. note:: If ``http_proxy`` or ``https_proxy`` is set in the 
environment
-                  this can cause difficulties with some of the intercepted 
libraries.
-                  If requests or urllib is being used, these will raise an 
exception
-                  if one of those variables is set.
-        
-        .. note:: If ``wsgi_intercept.STRICT_RESPONSE_HEADERS`` is set to 
``True``
-                  then response headers sent by an application will be checked 
to
-                  make sure they are of the type ``str`` native to the version 
of
-                  Python, as required by pep 3333. The default is ``False`` (to
-                  preserve backwards compatibility)
-        
-        
-        Install
-        =======
-        
-        ::
-        
-            pip install -U wsgi_intercept
-        
-        Packages Intercepted
-        ====================
-        
-        Unfortunately each of the HTTP client libraries use their own specific
-        mechanism for making HTTP call-outs, so individual implementations are
-        needed. At this time there are implementations for ``httplib2``,
-        ``urllib3`` and ``requests`` in both Python 2 and 3, ``urllib2`` and
-        ``httplib`` in Python 2 and ``urllib.request`` and ``http.client``
-        in Python 3.
-        
-        If you are using Python 2 and need support for a different HTTP
-        client, require a version of ``wsgi_intercept<0.6``. Earlier versions
-        include support for ``webtest``, ``webunit`` and ``zope.testbrowser``.
-        
-        The best way to figure out how to use interception is to inspect
-        `the tests`_. More comprehensive documentation available upon
-        request.
-        
-        .. _the tests: https://github.com/cdent/wsgi-intercept/tree/master/test
-        
-        
-        History
-        =======
-        
-        Pursuant to Ian Bicking's `"best Web testing framework"`_ post, Titus
-        Brown put together an `in-process HTTP-to-WSGI interception mechanism`_
-        for his own Web testing system, twill. Because the mechanism is pretty
-        generic -- it works at the httplib level -- Titus decided to try adding
-        it into all of the *other* Python Web testing frameworks.
-        
-        The Python 2 version of wsgi-intercept was the result. Kumar McMillan
-        later took over maintenance.
-        
-        The current version is tested with Python 2.7, 3.5-3.8, and pypy and 
pypy3.
-        It was assembled by `Chris Dent`_. Testing and documentation 
improvements
-        from `Sasha Hart`_.
-        
-        .. _"best Web testing framework":
-             
http://blog.ianbicking.org/best-of-the-web-app-test-frameworks.html
-        .. _in-process HTTP-to-WSGI interception mechanism:
-             http://www.advogato.org/person/titus/diary.html?start=119
-        .. _WSGI application: http://www.python.org/peps/pep-3333.html
-        .. _Chris Dent: https://github.com/cdent
-        .. _Sasha Hart: https://github.com/sashahart
-        
-        Project Home
-        ============
-        
-        This project lives on `GitHub`_. Please submit all bugs, patches,
-        failing tests, et cetera using the Issue Tracker.
-        
-        Additional documentation is available on `Read The Docs`_.
-        
-        .. _GitHub: http://github.com/cdent/wsgi-intercept
-        .. _Read The Docs: http://wsgi-intercept.readthedocs.org/en/latest/
-        
 Platform: UNKNOWN
 Classifier: Environment :: Web Environment
 Classifier: Intended Audience :: Developers
@@ -162,3 +22,146 @@
 Classifier: Topic :: Software Development :: Testing
 Provides-Extra: testing
 Provides-Extra: docs
+License-File: LICENSE
+
+Installs a WSGI application in place of a real host for testing.
+
+Introduction
+============
+
+Testing a WSGI application sometimes involves starting a server at a
+local host and port, then pointing your test code to that address.
+Instead, this library lets you intercept calls to any specific host/port
+combination and redirect them into a `WSGI application`_ importable by
+your test program. Thus, you can avoid spawning multiple processes or
+threads to test your Web app.
+
+Supported Libaries
+==================
+
+``wsgi_intercept`` works with a variety of HTTP clients in Python 2.7,
+3.5 and beyond, and in pypy.
+
+* urllib2
+* urllib.request
+* httplib
+* http.client
+* httplib2
+* requests
+* urllib3
+
+How Does It Work?
+=================
+
+``wsgi_intercept`` works by replacing ``httplib.HTTPConnection`` with a
+subclass, ``wsgi_intercept.WSGI_HTTPConnection``. This class then
+redirects specific server/port combinations into a WSGI application by
+emulating a socket. If no intercept is registered for the host and port
+requested, those requests are passed on to the standard handler.
+
+The easiest way to use an intercept is to import an appropriate subclass
+of ``~wsgi_intercept.interceptor.Interceptor`` and use that as a
+context manager over web requests that use the library associated with
+the subclass. For example::
+
+    import httplib2
+    from wsgi_intercept.interceptor import Httplib2Interceptor
+    from mywsgiapp import app
+
+    def load_app():
+        return app
+
+    http = httplib2.Http()
+    with Httplib2Interceptor(load_app, host='example.com', port=80) as url:
+        response, content = http.request('%s%s' % (url, '/path'))
+        assert response.status == 200
+
+The interceptor class may aslo be used directly to install intercepts.
+See the module documentation for more information.
+
+Older versions required that the functions ``add_wsgi_intercept(host,
+port, app_create_fn, script_name='')`` and ``remove_wsgi_intercept(host,port)``
+be used to specify which URLs should be redirected into what applications.
+These methods are still available, but the ``Interceptor`` classes are likely
+easier to use for most use cases.
+
+.. note:: ``app_create_fn`` is a *function object* returning a WSGI
+          application; ``script_name`` becomes ``SCRIPT_NAME`` in the WSGI
+          app's environment, if set.
+
+.. note:: If ``http_proxy`` or ``https_proxy`` is set in the environment
+          this can cause difficulties with some of the intercepted libraries.
+          If requests or urllib is being used, these will raise an exception
+          if one of those variables is set.
+
+.. note:: If ``wsgi_intercept.STRICT_RESPONSE_HEADERS`` is set to ``True``
+          then response headers sent by an application will be checked to
+          make sure they are of the type ``str`` native to the version of
+          Python, as required by pep 3333. The default is ``False`` (to
+          preserve backwards compatibility)
+
+
+Install
+=======
+
+::
+
+    pip install -U wsgi_intercept
+
+Packages Intercepted
+====================
+
+Unfortunately each of the HTTP client libraries use their own specific
+mechanism for making HTTP call-outs, so individual implementations are
+needed. At this time there are implementations for ``httplib2``,
+``urllib3`` and ``requests`` in both Python 2 and 3, ``urllib2`` and
+``httplib`` in Python 2 and ``urllib.request`` and ``http.client``
+in Python 3.
+
+If you are using Python 2 and need support for a different HTTP
+client, require a version of ``wsgi_intercept<0.6``. Earlier versions
+include support for ``webtest``, ``webunit`` and ``zope.testbrowser``.
+
+The best way to figure out how to use interception is to inspect
+`the tests`_. More comprehensive documentation available upon
+request.
+
+.. _the tests: https://github.com/cdent/wsgi-intercept/tree/master/test
+
+
+History
+=======
+
+Pursuant to Ian Bicking's `"best Web testing framework"`_ post, Titus
+Brown put together an `in-process HTTP-to-WSGI interception mechanism`_
+for his own Web testing system, twill. Because the mechanism is pretty
+generic -- it works at the httplib level -- Titus decided to try adding
+it into all of the *other* Python Web testing frameworks.
+
+The Python 2 version of wsgi-intercept was the result. Kumar McMillan
+later took over maintenance.
+
+The current version is tested with Python 2.7, 3.5-3.8, and pypy and pypy3.
+It was assembled by `Chris Dent`_. Testing and documentation improvements
+from `Sasha Hart`_.
+
+.. _"best Web testing framework":
+     http://blog.ianbicking.org/best-of-the-web-app-test-frameworks.html
+.. _in-process HTTP-to-WSGI interception mechanism:
+     http://www.advogato.org/person/titus/diary.html?start=119
+.. _WSGI application: http://www.python.org/peps/pep-3333.html
+.. _Chris Dent: https://github.com/cdent
+.. _Sasha Hart: https://github.com/sashahart
+
+Project Home
+============
+
+This project lives on `GitHub`_. Please submit all bugs, patches,
+failing tests, et cetera using the Issue Tracker.
+
+Additional documentation is available on `Read The Docs`_.
+
+.. _GitHub: http://github.com/cdent/wsgi-intercept
+.. _Read The Docs: http://wsgi-intercept.readthedocs.org/en/latest/
+
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/wsgi_intercept-1.9.2/wsgi_intercept.egg-info/SOURCES.txt 
new/wsgi_intercept-1.10.0/wsgi_intercept.egg-info/SOURCES.txt
--- old/wsgi_intercept-1.9.2/wsgi_intercept.egg-info/SOURCES.txt        
2020-02-05 12:15:55.000000000 +0100
+++ new/wsgi_intercept-1.10.0/wsgi_intercept.egg-info/SOURCES.txt       
2022-05-16 13:43:18.000000000 +0200
@@ -40,4 +40,5 @@
 wsgi_intercept/tests/test_urllib.py
 wsgi_intercept/tests/test_urllib3.py
 wsgi_intercept/tests/test_wsgi_compliance.py
+wsgi_intercept/tests/test_wsgiref.py
 wsgi_intercept/tests/wsgi_app.py
\ No newline at end of file

Reply via email to