Hello community,
here is the log from the commit of package python-pytest-localserver for
openSUSE:Leap:15.2 checked in at 2020-03-31 07:21:47
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Leap:15.2/python-pytest-localserver (Old)
and /work/SRC/openSUSE:Leap:15.2/.python-pytest-localserver.new.3160 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pytest-localserver"
Tue Mar 31 07:21:47 2020 rev:12 rq:789505 version:0.5.0
Changes:
--------
---
/work/SRC/openSUSE:Leap:15.2/python-pytest-localserver/python-pytest-localserver.changes
2020-01-15 15:52:17.975558569 +0100
+++
/work/SRC/openSUSE:Leap:15.2/.python-pytest-localserver.new.3160/python-pytest-localserver.changes
2020-03-31 07:21:48.846383552 +0200
@@ -1,0 +2,20 @@
+Fri Feb 22 21:12:05 CET 2019 - Matej Cepl <[email protected]>
+
+- Add remove_bindir.patch making test suite pass by removing
+ '/usr/bin' from sys.path.
+
+-------------------------------------------------------------------
+Wed Feb 20 12:11:06 UTC 2019 - Tomáš Chvátal <[email protected]>
+
+- Drop the patch python-pytest-localserver-do-not-use-shipped-pem.patch
+ * We actually want the local pem as it is used just for the test
+ spawning where we validate against it
+
+-------------------------------------------------------------------
+Thu Feb 14 14:20:49 UTC 2019 - Tomáš Chvátal <[email protected]>
+
+- Update to 0.5.0:
+ * New feature: SMTP email message objects now include a ``details``
+ property capturing the envelope details.
+
+-------------------------------------------------------------------
Old:
----
pytest-localserver-0.4.1.tar.gz
python-pytest-localserver-do-not-use-shipped-pem.patch
New:
----
pytest-localserver-0.5.0.tar.gz
remove_bindir.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-pytest-localserver.spec ++++++
--- /var/tmp/diff_new_pack.k1S90W/_old 2020-03-31 07:21:49.334383763 +0200
+++ /var/tmp/diff_new_pack.k1S90W/_new 2020-03-31 07:21:49.346383769 +0200
@@ -1,7 +1,7 @@
#
# spec file for package python-pytest-localserver
#
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2015 LISA GmbH, Bingen, Germany.
#
# All modifications and additions to the file contributed by third parties
@@ -13,28 +13,29 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-pytest-localserver
-Version: 0.4.1
+Version: 0.5.0
Release: 0
Summary: Plugin for py.test to test server connections locally
License: MIT
Group: Development/Languages/Python
-Url: https://bitbucket.org/pytest-dev/pytest-localserver
+URL: https://bitbucket.org/pytest-dev/pytest-localserver
Source:
https://files.pythonhosted.org/packages/source/p/pytest-localserver/pytest-localserver-%{version}.tar.gz
-Patch0: python-pytest-localserver-do-not-use-shipped-pem.patch
-BuildRequires: %{python_module devel}
+Patch0: remove_bindir.patch
+BuildRequires: %{python_module Werkzeug >= 0.10}
+BuildRequires: %{python_module pytest >= 2.0.0}
+BuildRequires: %{python_module requests}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
-Requires: python-Werkzeug
-Requires: python-pytest
+Requires: python-Werkzeug >= 0.10
+Requires: python-pytest >= 2.0.0
BuildArch: noarch
-
%python_subpackages
%description
@@ -49,23 +50,17 @@
%prep
%setup -q -n pytest-localserver-%{version}
-%patch0 -p1
-rm -f pytest_localserver/server.pem.orig
+%autopatch -p1
%build
%python_build
%install
%python_install
-%{python_expand rm -f
%{buildroot}%{$python_sitelib}/pytest_localserver/server.pem
-chmod a+x %{buildroot}%{$python_sitelib}/pytest_localserver/smtp.py
-chmod a+x %{buildroot}%{$python_sitelib}/pytest_localserver/plugin.py
-sed -i "s|^#!/usr/bin/env python$|#!%__$python|"
%{buildroot}%{$python_sitelib}/pytest_localserver/smtp.py
-sed -i "s|^#!/usr/bin/env python$|#!%__$python|"
%{buildroot}%{$python_sitelib}/pytest_localserver/plugin.py
-$python -m compileall -d %{$python_sitelib}
%{buildroot}%{$python_sitelib}/pytest_localserver/
-$python -O -m compileall -d %{$python_sitelib}
%{buildroot}%{$python_sitelib}/pytest_localserver/
-%fdupes %{buildroot}%{$python_sitelib}
-}
+%python_expand %fdupes %{buildroot}%{$python_sitelib}
+
+%check
+%python_expand py.test-%{$python_bin_suffix} -v -s
%files %{python_files}
%doc README
++++++ pytest-localserver-0.4.1.tar.gz -> pytest-localserver-0.5.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-localserver-0.4.1/PKG-INFO
new/pytest-localserver-0.5.0/PKG-INFO
--- old/pytest-localserver-0.4.1/PKG-INFO 2017-11-28 13:29:40.000000000
+0100
+++ new/pytest-localserver-0.5.0/PKG-INFO 2018-11-14 11:57:45.000000000
+0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: pytest-localserver
-Version: 0.4.1
+Version: 0.5.0
Summary: py.test plugin to test server connections locally.
Home-page: http://bitbucket.org/pytest-dev/pytest-localserver/
Author: Sebastian Rahlf
@@ -229,4 +229,6 @@
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
+Classifier: Programming Language :: Python :: 3.6
+Classifier: Programming Language :: Python :: 3.7
Classifier: Topic :: Software Development :: Testing
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/pytest-localserver-0.4.1/pytest_localserver/__init__.py
new/pytest-localserver-0.5.0/pytest_localserver/__init__.py
--- old/pytest-localserver-0.4.1/pytest_localserver/__init__.py 2017-11-28
13:28:36.000000000 +0100
+++ new/pytest-localserver-0.5.0/pytest_localserver/__init__.py 2018-11-14
11:55:42.000000000 +0100
@@ -1 +1 @@
-VERSION = '0.4.1'
+VERSION = '0.5.0'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-localserver-0.4.1/pytest_localserver/smtp.py
new/pytest-localserver-0.5.0/pytest_localserver/smtp.py
--- old/pytest-localserver-0.4.1/pytest_localserver/smtp.py 2017-11-28
13:19:33.000000000 +0100
+++ new/pytest-localserver-0.5.0/pytest_localserver/smtp.py 2018-11-14
11:50:26.000000000 +0100
@@ -10,9 +10,12 @@
import asyncore
import email
import smtpd
+import sys
import threading
+PY35_OR_NEWER = sys.version_info[:2] >= (3, 5)
+
class Server (smtpd.SMTPServer, threading.Thread):
"""
@@ -32,7 +35,12 @@
WAIT_BETWEEN_CHECKS = 0.001
def __init__(self, host='localhost', port=0):
- smtpd.SMTPServer.__init__(self, (host, port), None)
+ # Workaround for deprecated signature in Python 3.6
+ if PY35_OR_NEWER:
+ smtpd.SMTPServer.__init__(self, (host, port), None,
decode_data=True)
+ else:
+ smtpd.SMTPServer.__init__(self, (host, port), None)
+
if self._localaddr[1] == 0:
self.addr = self.socket.getsockname()
@@ -48,9 +56,22 @@
Adds message to outbox.
"""
try:
- self.outbox += [email.message_from_bytes(data)]
+ message = email.message_from_bytes(data)
except AttributeError:
- self.outbox += [email.message_from_string(data)]
+ message = email.message_from_string(data)
+ # on the message, also set the envelope details
+
+ class Bunch:
+ def __init__(self, **kwds):
+ vars(self).update(kwds)
+
+ message.details = Bunch(
+ peer=peer,
+ mailfrom=mailfrom,
+ rcpttos=rcpttos,
+ **kwargs
+ )
+ self.outbox.append(message)
def run(self):
"""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/pytest-localserver-0.4.1/pytest_localserver.egg-info/PKG-INFO
new/pytest-localserver-0.5.0/pytest_localserver.egg-info/PKG-INFO
--- old/pytest-localserver-0.4.1/pytest_localserver.egg-info/PKG-INFO
2017-11-28 13:29:39.000000000 +0100
+++ new/pytest-localserver-0.5.0/pytest_localserver.egg-info/PKG-INFO
2018-11-14 11:57:45.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: pytest-localserver
-Version: 0.4.1
+Version: 0.5.0
Summary: py.test plugin to test server connections locally.
Home-page: http://bitbucket.org/pytest-dev/pytest-localserver/
Author: Sebastian Rahlf
@@ -229,4 +229,6 @@
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
+Classifier: Programming Language :: Python :: 3.6
+Classifier: Programming Language :: Python :: 3.7
Classifier: Topic :: Software Development :: Testing
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-localserver-0.4.1/setup.cfg
new/pytest-localserver-0.5.0/setup.cfg
--- old/pytest-localserver-0.4.1/setup.cfg 2017-11-28 13:29:40.000000000
+0100
+++ new/pytest-localserver-0.5.0/setup.cfg 2018-11-14 11:57:45.000000000
+0100
@@ -4,5 +4,4 @@
[egg_info]
tag_build =
tag_date = 0
-tag_svn_revision = 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-localserver-0.4.1/setup.py
new/pytest-localserver-0.5.0/setup.py
--- old/pytest-localserver-0.4.1/setup.py 2017-11-28 13:28:45.000000000
+0100
+++ new/pytest-localserver-0.5.0/setup.py 2018-11-14 11:55:42.000000000
+0100
@@ -2,7 +2,7 @@
import sys
-VERSION = '0.4.1'
+VERSION = '0.5.0'
def read(fname):
@@ -46,7 +46,6 @@
cmdclass={'test': PyTest},
tests_require=[
'pytest>=2.0.0',
- 'six',
'requests'
],
entry_points={
@@ -69,6 +68,8 @@
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
+ 'Programming Language :: Python :: 3.6',
+ 'Programming Language :: Python :: 3.7',
'Topic :: Software Development :: Testing'
]
)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-localserver-0.4.1/tests/test_http.py
new/pytest-localserver-0.5.0/tests/test_http.py
--- old/pytest-localserver-0.4.1/tests/test_http.py 2017-11-28
13:19:33.000000000 +0100
+++ new/pytest-localserver-0.5.0/tests/test_http.py 2018-11-14
11:31:40.000000000 +0100
@@ -1,9 +1,6 @@
-import gzip
import requests
-import six
from pytest_localserver import http, plugin
-from pytest_localserver import VERSION
# define test fixture here again in order to run tests without having to
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-localserver-0.4.1/tests/test_smtp.py
new/pytest-localserver-0.5.0/tests/test_smtp.py
--- old/pytest-localserver-0.4.1/tests/test_smtp.py 2017-11-28
13:19:33.000000000 +0100
+++ new/pytest-localserver-0.5.0/tests/test_smtp.py 2018-11-14
11:50:26.000000000 +0100
@@ -65,6 +65,9 @@
assert msg['To'] == '[email protected]'
assert msg['From'] == '[email protected]'
assert msg['Subject'] == 'Your e-mail is getting there'
+ assert msg.details.rcpttos == ['[email protected]']
+ assert msg.details.peer
+ assert msg.details.mailfrom
# send another e-mail
send_plain_email(
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/pytest-localserver-0.4.1/tox.ini
new/pytest-localserver-0.5.0/tox.ini
--- old/pytest-localserver-0.4.1/tox.ini 2017-11-28 13:19:33.000000000
+0100
+++ new/pytest-localserver-0.5.0/tox.ini 2018-11-14 11:29:44.000000000
+0100
@@ -1,5 +1,5 @@
[tox]
-envlist = py26,py27,py33,py34,py35,py36
+envlist = py26,py27,py33,py34,py35,py36,py37
recreate = True
[tox:hudson]
++++++ remove_bindir.patch ++++++
--- /dev/null
+++ b/tests/__init__.py
@@ -0,0 +1,3 @@
+import sys
+if '/usr/bin' in sys.path:
+ del sys.path[sys.path.index('/usr/bin')]