--- python-mock-services-0.2.orig/debian/changelog +++ python-mock-services-0.2/debian/changelog @@ -0,0 +1,8 @@ +python-mock-services (0.2-0ubuntu0.16.04.1) xenial; urgency=medium + + [ Chuck Short ] + * debian/python3-mock-services: Fix co-dependency install. + * debian/control: Add dependency of python-nose. + * Initial release (LP: #1623107). + + -- Corey Bryant Wed, 12 Oct 2016 13:46:07 -0400 --- python-mock-services-0.2.orig/debian/compat +++ python-mock-services-0.2/debian/compat @@ -0,0 +1 @@ +9 --- python-mock-services-0.2.orig/debian/control +++ python-mock-services-0.2/debian/control @@ -0,0 +1,47 @@ +Source: python-mock-services +Section: python +Priority: extra +Maintainer: Chuck Short +Build-Depends: debhelper (>=9),dh-python, python-all (>= 2.6.6-3~), + python-setuptools, python3-all, python3-setuptools, + python-attr, python-funcsigs, python-requests-mock, python3-attr, + python3-funcsigs, python3-requests-mock, quilt, python-nose, python3-nose +Standards-Version: 3.9.8 +X-Python-Version: >= 2.6 +X-Python3-Version: >= 3.2 + +Package: python-mock-services +Architecture: all +Depends: python-attr, python-funcsigs, python-requests-mock, ${python:Depends}, ${misc:Depends} +Suggests: python-python-mock-services-doc +Description: Provides an easy way of mocking API Services (Python 2) + Aims to provide an easy way to mock an entire service API based on requests-mock + and a simple dict definition of a service. The idea is to + mock everything at start according given rules. + Then mock-services allows to start/stop http mock locally. + . + This package installs the library for Python 2. + +Package: python3-mock-services +Architecture: all +Depends: python3-attr, python3-funcsigs, python3-requests-mock, ${python3:Depends}, ${misc:Depends} +Suggests: python-python-mock-services-doc +Description: Provides an easy way of mocking API Services (Python 3) + Aims to provide an easy way to mock an entire service API based on + requests-mock and a simple dict definition of a service. The idea is to + mock everything at start according given rules. + Then mock-services allows to start/stop http mock locally + . + This package installs the library for Python 3. + +Package: python-mock-services-doc +Architecture: all +Section: doc +Depends: ${sphinxdoc:Depends}, ${misc:Depends} +Description: (common documentation) + Aims to provide an easy way to mock an entire service API based on requests-mock + and a simple dict definition of a service. The idea is to + mock everything at start according given rules. + Then mock-services allows to start/stop http mock locally. + . + This is the common documentation package. --- python-mock-services-0.2.orig/debian/copyright +++ python-mock-services-0.2/debian/copyright @@ -0,0 +1,46 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: mock-services +Source: https://github.com/novafloss/mock-services + +Files: * +Copyright: 2015 Novapost/PeopleDoc +License: MIT + 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. + + +Files: debian/* +Copyright: 2016 Canonical Ltd +License: MIT + 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 --- python-mock-services-0.2.orig/debian/patches/fix-python3.patch +++ python-mock-services-0.2/debian/patches/fix-python3.patch @@ -0,0 +1,19 @@ +Description: Fix mock-services running on python3 +Author: Chuck Short +Forwarded: Not-Needed +diff -Naurp python-mock-services-0.2.orig/mock_services/service.py python-mock-services-0.2/mock_services/service.py +--- python-mock-services-0.2.orig/mock_services/service.py 2016-01-07 06:25:37.000000000 -0500 ++++ python-mock-services-0.2/mock_services/service.py 2016-05-31 09:27:52.496065745 -0400 +@@ -2,7 +2,11 @@ + import json + import logging + import re +-import urlparse ++try: ++ from urllib import parse as urlparse ++except ImportError: ++ import urlparse ++ + + import attr + --- python-mock-services-0.2.orig/debian/patches/series +++ python-mock-services-0.2/debian/patches/series @@ -0,0 +1 @@ +fix-python3.patch --- python-mock-services-0.2.orig/debian/python-mock-services.install +++ python-mock-services-0.2/debian/python-mock-services.install @@ -0,0 +1 @@ +usr/lib/python2.7/dist-packages/* --- python-mock-services-0.2.orig/debian/python3-mock-services.install +++ python-mock-services-0.2/debian/python3-mock-services.install @@ -0,0 +1 @@ +usr/lib/python3.5/dist-packages/* --- python-mock-services-0.2.orig/debian/rules +++ python-mock-services-0.2/debian/rules @@ -0,0 +1,9 @@ +#!/usr/bin/make -f + + +%: + dh $@ --with python2,python3 --buildsystem=pybuild + +override_dh_auto_test: + PYTHONPATH=. nosetests + --- python-mock-services-0.2.orig/debian/watch +++ python-mock-services-0.2/debian/watch @@ -0,0 +1,3 @@ +version=3 +opts=uversionmangle=s/(rc|a|b|c)/~$1/ \ +https://pypi.debian.net/mock-services/mock-services-(.+)\.(?:zip|tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz))) --- python-mock-services-0.2.orig/mock_services.egg-info/SOURCES.txt +++ python-mock-services-0.2/mock_services.egg-info/SOURCES.txt @@ -7,13 +7,21 @@ setup.cfg setup.py mock_services/__init__.py +mock_services/__init__.pyc mock_services/decorators.py +mock_services/decorators.pyc mock_services/exceptions.py +mock_services/exceptions.pyc mock_services/helpers.py +mock_services/helpers.pyc mock_services/http_mock.py +mock_services/http_mock.pyc mock_services/rules.py +mock_services/rules.pyc mock_services/service.py +mock_services/service.pyc mock_services/storage.py +mock_services/storage.pyc mock_services.egg-info/PKG-INFO mock_services.egg-info/SOURCES.txt mock_services.egg-info/dependency_links.txt --- python-mock-services-0.2.orig/mock_services/service.py +++ python-mock-services-0.2/mock_services/service.py @@ -2,7 +2,11 @@ import json import logging import re -import urlparse +try: + from urllib import parse as urlparse +except ImportError: + import urlparse + import attr