public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/python-photutils] epel10: fixed tests
@ 2026-06-26 3:41 Christian Dersch
0 siblings, 0 replies; only message in thread
From: Christian Dersch @ 2026-06-26 3:41 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/python-photutils
Branch : epel10
Commit : 794fd9f9002501fa2f69eb78b953661e4b70cc7b
Author : Christian Dersch <lupinix@mailbox.org>
Date : 2017-10-10T15:53:34+02:00
Stats : +61/-7 in 3 file(s)
URL : https://src.fedoraproject.org/rpms/python-photutils/c/794fd9f9002501fa2f69eb78b953661e4b70cc7b?branch=epel10
Log:
fixed tests
---
diff --git a/python-photutils-Use-astropy_helpers-provided-by-the-system.patch b/python-photutils-Use-astropy_helpers-provided-by-the-system.patch
new file mode 100644
index 0000000..201f6d3
--- /dev/null
+++ b/python-photutils-Use-astropy_helpers-provided-by-the-system.patch
@@ -0,0 +1,21 @@
+From: Ole Streicher <olebole@debian.org>
+Date: Thu, 7 Jul 2016 10:26:43 +0200
+Subject: Use astropy_helpers provided by the system
+
+---
+ setup.cfg | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/setup.cfg b/setup.cfg
+index e7881d0..2d23bfd 100644
+--- a/setup.cfg
++++ b/setup.cfg
+@@ -13,7 +13,7 @@ norecursedirs = build docs/_build
+ doctest_plus = enabled
+
+ [ah_bootstrap]
+-auto_use = True
++auto_use = False
+
+ [metadata]
+ package_name = photutils
diff --git a/python-photutils-changing-parametrized-tests-pytest-3.2.0-compatible.patch b/python-photutils-changing-parametrized-tests-pytest-3.2.0-compatible.patch
new file mode 100644
index 0000000..289b41a
--- /dev/null
+++ b/python-photutils-changing-parametrized-tests-pytest-3.2.0-compatible.patch
@@ -0,0 +1,23 @@
+From: Brigitta Sipocz <bsipocz@gmail.com>
+Date: Wed, 2 Aug 2017 20:00:15 +0100
+Subject: changing parametrized tests pytest 3.2.0 compatible
+
+---
+ photutils/psf/tests/test_photometry.py | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/photutils/psf/tests/test_photometry.py b/photutils/psf/tests/test_photometry.py
+index 2141120..4441ca3 100644
+--- a/photutils/psf/tests/test_photometry.py
++++ b/photutils/psf/tests/test_photometry.py
+@@ -165,8 +165,8 @@ def test_psf_photometry_niters(sigma_psf, sources):
+ (sigma_psfs[1], sources2),
+ # these ensure that the test *fails* if the model
+ # PSFs are the wrong shape
+- pytest.mark.xfail((sigma_psfs[0]/1.2, sources1)),
+- pytest.mark.xfail((sigma_psfs[1]*1.2, sources2))])
++ pytest.param(sigma_psfs[0]/1.2, sources1, marks=pytest.mark.xfail()),
++ pytest.param(sigma_psfs[1]*1.2, sources2, marks=pytest.mark.xfail())])
+ def test_psf_photometry_oneiter(sigma_psf, sources):
+ """
+ Tests in an image with a group of two overlapped stars and an
diff --git a/python-photutils.spec b/python-photutils.spec
index 02ebb32..80ec08b 100644
--- a/python-photutils.spec
+++ b/python-photutils.spec
@@ -2,13 +2,18 @@
Name: python-%{srcname}
Version: 0.3.2
-Release: 3%{?dist}
+Release: 4%{?dist}
Summary: Astropy affiliated package for image photometry tasks
License: BSD
URL: http://photutils.readthedocs.org/en/latest/index.html
Source0: https://pypi.io/packages/source/p/photutils/%{srcname}-%{version}.tar.gz
+# Use system copy of astropy-helpers
+Patch0: python-photutils-Use-astropy_helpers-provided-by-the-system.patch
+# Fix tests with pytest >= 3.2
+Patch1: python-photutils-changing-parametrized-tests-pytest-3.2.0-compatible.patch
+
BuildRequires: python2-devel python3-devel
%description
@@ -23,11 +28,12 @@ Photutils contains functions for:
Summary: Astropy affiliated package for image photometry tasks
BuildRequires: python2-devel
-BuildRequires: Cython
-BuildRequires: numpy
+BuildRequires: python2-Cython
+BuildRequires: python2-numpy
BuildRequires: python2-astropy
+BuildRequires: python2-astropy-helpers
# Optional
-BuildRequires: scipy
+BuildRequires: python2-scipy
BuildRequires: python2-scikit-image
BuildRequires: python-matplotlib
# For tests
@@ -35,9 +41,9 @@ BuildRequires: python2-pytest
%{?python_provide:%python_provide python2-%{srcname}}
-Requires: numpy
+Requires: python2-numpy
Requires: python2-astropy
-Recommends: scipy
+Recommends: python2-scipy
Recommends: python2-scikit-image
Recommends: python2-matplotlib
@@ -56,6 +62,7 @@ BuildRequires: python3-devel
BuildRequires: python3-Cython
BuildRequires: python3-numpy
BuildRequires: python3-astropy
+BuildRequires: python3-astropy-helpers
# Optional
BuildRequires: python3-scipy
BuildRequires: python3-scikit-image
@@ -80,7 +87,7 @@ Photutils contains functions for:
* performing aperture and PSF photometry
%prep
-%autosetup -n %{srcname}-%{version}
+%autosetup -p1 -n %{srcname}-%{version}
%build
%py2_build
@@ -122,6 +129,9 @@ popd
%{python3_sitearch}/%{srcname}
%changelog
+* Tue Oct 10 2017 Christian Dersch <lupinix@mailbox.org> - 0.3.2-4
+- Fixed tests
+
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-06-26 3:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-06-26 3:41 [rpms/python-photutils] epel10: fixed tests Christian Dersch
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox