Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-django-assets for
openSUSE:Factory checked in at 2021-10-26 20:13:50
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-django-assets (Old)
and /work/SRC/openSUSE:Factory/.python-django-assets.new.1890 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-django-assets"
Tue Oct 26 20:13:50 2021 rev:2 rq:927413 version:2.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-django-assets/python-django-assets.changes
2020-06-15 20:32:33.130806745 +0200
+++
/work/SRC/openSUSE:Factory/.python-django-assets.new.1890/python-django-assets.changes
2021-10-26 20:14:31.802036312 +0200
@@ -1,0 +2,7 @@
+Tue Oct 26 05:58:30 UTC 2021 - Steve Kowalik <[email protected]>
+
+- Add patch remove-nose.patch:
+ * Stop using nose assert methods.
+- Switch to using pytest to run the testsuite.
+
+-------------------------------------------------------------------
New:
----
remove-nose.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-django-assets.spec ++++++
--- /var/tmp/diff_new_pack.Cpzyao/_old 2021-10-26 20:14:32.314036582 +0200
+++ /var/tmp/diff_new_pack.Cpzyao/_new 2021-10-26 20:14:32.314036582 +0200
@@ -1,7 +1,7 @@
#
# spec file for package python-django-assets
#
-# Copyright (c) 2020 SUSE LLC
+# Copyright (c) 2021 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -26,6 +26,7 @@
Group: Development/Languages/Python
URL: https://github.com/miracle2k/django-assets
Source:
https://files.pythonhosted.org/packages/source/d/django-assets/django-assets-%{version}.tar.gz
+Patch0: remove-nose.patch
BuildRequires: %{python_module setuptools}
BuildRequires: dos2unix
BuildRequires: fdupes
@@ -35,7 +36,7 @@
BuildArch: noarch
# SECTION test requirements
BuildRequires: %{python_module Django >= 1.7}
-BuildRequires: %{python_module nose}
+BuildRequires: %{python_module pytest}
BuildRequires: %{python_module webassets >= 2.0}
# /SECTION
%python_subpackages
@@ -46,6 +47,7 @@
%prep
%setup -q -n django-assets-%{version}
dos2unix README.rst
+%autopatch -p1
%build
%python_build
@@ -55,7 +57,7 @@
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
-%python_exec setup.py test
+%pytest
%files %{python_files}
%doc CHANGES README.rst
++++++ remove-nose.patch ++++++
Index: django-assets-2.0/tests/__init__.py
===================================================================
--- django-assets-2.0.orig/tests/__init__.py
+++ django-assets-2.0/tests/__init__.py
@@ -1,4 +1,4 @@
-from nose import SkipTest
+from unittest import SkipTest
try:
import django
except ImportError:
Index: django-assets-2.0/tests/test_django.py
===================================================================
--- django-assets-2.0.orig/tests/test_django.py
+++ django-assets-2.0/tests/test_django.py
@@ -1,7 +1,6 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
-from nose import SkipTest
-from nose.tools import assert_raises, assert_raises_regexp
+from unittest import SkipTest
from django.conf import settings
from django.contrib.staticfiles import finders
@@ -239,7 +238,12 @@ class TestStaticFiles(TempEnvironmentHel
"""
settings.ASSETS_DEBUG = False
bundle = self.mkbundle('file1', 'file2', output="out")
- assert_raises(BundleError, bundle.build)
+ try:
+ bundle.build()
+ except BundleError:
+ pass
+ else:
+ raise AssertionError("BundleError not raised")
# After creating the files in the static root directory,
# it works (we only look there in production).
@@ -264,8 +268,12 @@ class TestStaticFiles(TempEnvironmentHel
"""An error is raised if a source file is missing.
"""
bundle = self.mkbundle('xyz', output="out")
- assert_raises_regexp(
- BundleError, 'using staticfiles finders', bundle.build)
+ try:
+ bundle.build()
+ except BundleError as e:
+ assert "using staticfiles finders" in str(e)
+ else:
+ raise AssertionError("BundleError not raised")
def test_serve_built_files(self):
"""The files we write to STATIC_ROOT are served in debug mode