1 | %define modname nose |
---|
2 | %define pkg_release 1%{?_dist_release} |
---|
3 | |
---|
4 | Name: python-nose |
---|
5 | Version: 1.3.7 |
---|
6 | Release: %{pkg_release} |
---|
7 | Summary: A discovery-based unittest extension for Python |
---|
8 | Summary(ja): Python 用の発見型ユニットテスト・エクステンション |
---|
9 | |
---|
10 | Group: Development/Languages |
---|
11 | License: LGPLv2 |
---|
12 | URL: http://somethingaboutorange.com/mrl/projects/nose/ |
---|
13 | Vendor: Project Vine |
---|
14 | Distribution: Vine Linux |
---|
15 | |
---|
16 | Source0: http://somethingaboutorange.com/mrl/projects/nose/nose-%{version}.tar.gz |
---|
17 | |
---|
18 | # Make compatible with coverage 4.1 |
---|
19 | # https://github.com/nose-devs/nose/pull/1004 |
---|
20 | Patch0: python-nose-coverage4.patch |
---|
21 | # Fix python 3.5 compat |
---|
22 | # https://github.com/nose-devs/nose/pull/983 |
---|
23 | Patch1: python-nose-py35.patch |
---|
24 | # Fix UnicodeDecodeError with captured output |
---|
25 | # https://github.com/nose-devs/nose/pull/988 |
---|
26 | Patch2: python-nose-unicode.patch |
---|
27 | # Allow docutils to read utf-8 source |
---|
28 | Patch3: python-nose-readunicode.patch |
---|
29 | # Fix Python 3.6 compatibility |
---|
30 | # Python now returns ModuleNotFoundError instead of the previous ImportError |
---|
31 | # https://github.com/nose-devs/nose/pull/1029 |
---|
32 | Patch4: python-nose-py36.patch |
---|
33 | |
---|
34 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) |
---|
35 | |
---|
36 | BuildArch: noarch |
---|
37 | BuildRequires: dos2unix |
---|
38 | BuildRequires: python-devel, python-setuptools, python-rpm-macros |
---|
39 | BuildRequires: python3-devel, python3-setuptools, python3-rpm-macros |
---|
40 | Requires: python-setuptools |
---|
41 | |
---|
42 | |
---|
43 | %description |
---|
44 | nose: a discovery-based unittest extension. |
---|
45 | |
---|
46 | nose provides an alternate test discovery and running process for unittest, |
---|
47 | one that is intended to mimic the behavior of py.test as much as is |
---|
48 | reasonably possible without resorting to too much magic. |
---|
49 | |
---|
50 | |
---|
51 | %package -n python3-nose |
---|
52 | Summary: A discovery-based unittest extension for Python |
---|
53 | Summary(ja): Python 用の発見型ユニットテスト・エクステンション |
---|
54 | Group: Development/Languages |
---|
55 | Requires: python3-setuptools |
---|
56 | |
---|
57 | %description -n python3-nose |
---|
58 | nose: a discovery-based unittest extension. |
---|
59 | |
---|
60 | nose provides an alternate test discovery and running process for unittest, |
---|
61 | one that is intended to mimic the behavior of py.test as much as is |
---|
62 | reasonably possible without resorting to too much magic. |
---|
63 | |
---|
64 | %prep |
---|
65 | %setup -qc |
---|
66 | pushd %{modname}-%{version} |
---|
67 | %autopatch -p1 |
---|
68 | dos2unix examples/attrib_plugin.py |
---|
69 | cp -pr lgpl.txt AUTHORS CHANGELOG examples NEWS README.txt .. |
---|
70 | popd |
---|
71 | mv %{modname}-%{version} python2 |
---|
72 | cp -pr python2 python3 |
---|
73 | |
---|
74 | %build |
---|
75 | pushd python2 |
---|
76 | %py_build |
---|
77 | popd |
---|
78 | pushd python3 |
---|
79 | %py3_build |
---|
80 | popd |
---|
81 | |
---|
82 | %install |
---|
83 | rm -rf ${RPM_BUILD_ROOT} |
---|
84 | |
---|
85 | mkdir -p %{buildroot}%{_mandir}/man1 |
---|
86 | pushd python2 |
---|
87 | %py_install |
---|
88 | mv %{buildroot}%{_bindir}/nosetests{,-%{python_version}} |
---|
89 | ln -sf nosetests-%{python_version} %{buildroot}%{_bindir}/nosetests-2 |
---|
90 | mv %{buildroot}%{_prefix}/man/man1/nosetests.1 %{buildroot}%{_mandir}/man1/nosetests-%{python_version}.1 |
---|
91 | ln -sf nosetests-%{python_version}.1 %{buildroot}%{_mandir}/man1/nosetests-2.1 |
---|
92 | popd |
---|
93 | pushd python3 |
---|
94 | %py3_install |
---|
95 | mv %{buildroot}%{_bindir}/nosetests{,-%{python3_version}} |
---|
96 | ln -sf nosetests-%{python3_version} %{buildroot}%{_bindir}/nosetests-3 |
---|
97 | mv %{buildroot}%{_prefix}/man/man1/nosetests.1 %{buildroot}%{_mandir}/man1/nosetests-%{python3_version}.1 |
---|
98 | ln -sf nosetests-%{python3_version}.1 %{buildroot}%{_mandir}/man1/nosetests-3.1 |
---|
99 | popd |
---|
100 | |
---|
101 | ln -sf nosetests-2 %{buildroot}%{_bindir}/nosetests |
---|
102 | ln -sf nosetests-2.1 %{buildroot}%{_mandir}/man1/nosetests.1 |
---|
103 | |
---|
104 | %check |
---|
105 | pushd python2 |
---|
106 | %{__python} selftest.py |
---|
107 | popd |
---|
108 | pushd python3 |
---|
109 | %{__python3} setup.py build_tests |
---|
110 | %{__python3} selftest.py |
---|
111 | popd |
---|
112 | |
---|
113 | %clean |
---|
114 | rm -rf ${RPM_BUILD_ROOT} |
---|
115 | |
---|
116 | %files |
---|
117 | %defattr(-,root,root,-) |
---|
118 | %doc AUTHORS CHANGELOG lgpl.txt NEWS README.txt |
---|
119 | %{_bindir}/nosetests |
---|
120 | %{_bindir}/nosetests-2* |
---|
121 | %{_mandir}/man1/nosetests.1* |
---|
122 | %{_mandir}/man1/nosetests-2* |
---|
123 | %{python_sitelib}/nose-%{version}-py%{pyver}.egg-info |
---|
124 | %{python_sitelib}/nose |
---|
125 | |
---|
126 | %files -n python3-nose |
---|
127 | %defattr(-,root,root,-) |
---|
128 | %doc AUTHORS CHANGELOG lgpl.txt NEWS README.txt |
---|
129 | %{_bindir}/nosetests-3* |
---|
130 | %{_mandir}/man1/nosetests-3* |
---|
131 | %{python3_sitelib}/nose-%{version}-py%{python3_version}.egg-info |
---|
132 | %{python3_sitelib}/nose |
---|
133 | |
---|
134 | %changelog |
---|
135 | * Tue Nov 27 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.3.7-1 |
---|
136 | - new upstream release. |
---|
137 | - added python3 support. |
---|
138 | |
---|
139 | * Sun Apr 28 2013 Toshiharu Kudoh <toshi.kd2@gmail.com> 1.3.0-1 |
---|
140 | - new upstream release |
---|
141 | - deleted Patch0 |
---|
142 | |
---|
143 | * Sun Jun 24 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> 1.1.2-1 |
---|
144 | - new upstream release |
---|
145 | - added Patch0 from Debian sid to delete google analytics |
---|
146 | |
---|
147 | * Sat Feb 18 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.10.4-3 |
---|
148 | - rebuild with python-2.7.2 |
---|
149 | |
---|
150 | * Tue Feb 02 2010 Shu KONNO <owa@bg.wakwak.com> 0.10.4-2 |
---|
151 | - rebuild with python-2.6 |
---|
152 | |
---|
153 | * Sat Dec 20 2008 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.10.4-1 |
---|
154 | - initial build for Vine Linux based on fedora package |
---|
155 | |
---|
156 | * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.10.4-1 |
---|
157 | - Update to 0.10.4 to fix 2.6 issues |
---|
158 | |
---|
159 | * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.10.3-2 |
---|
160 | - Rebuild for Python 2.6 |
---|
161 | |
---|
162 | * Sat Aug 02 2008 Luke Macken <lmacken@redhat.com> 0.10.3-1 |
---|
163 | - Update to 0.10.3 |
---|
164 | |
---|
165 | * Thu Feb 28 2008 Luke Macken <lmacken@redhat.com> 0.10.1-1 |
---|
166 | - Update to 0.10.1 |
---|
167 | |
---|
168 | * Mon Dec 3 2007 Luke Macken <lmacken@redhat.com> 0.10.0-2 |
---|
169 | - Add python-setuptools to Requires (Bug #408491) |
---|
170 | |
---|
171 | * Tue Nov 27 2007 Luke Macken <lmacken@redhat.com> 0.10.0-1 |
---|
172 | - 0.10.0 |
---|
173 | |
---|
174 | * Sun Sep 2 2007 Luke Macken <lmacken@redhat.com> 0.10.0-0.3.b1 |
---|
175 | - Update for python-setuptools changes in rawhide |
---|
176 | |
---|
177 | * Tue Aug 21 2007 Luke Macken <lmacken@redhat.com> 0.10.0-0.2.b1 |
---|
178 | - 0.10.0b1 |
---|
179 | - Update license tag to LGPLv2 |
---|
180 | |
---|
181 | * Wed Jun 20 2007 Luke Macken <lmacken@redhat.com> 0.10.0-0.1.a2 |
---|
182 | - 0.10.0a2 |
---|
183 | |
---|
184 | * Sat Jun 2 2007 Luke Macken <lmacken@redhat.com> 0.9.3-1 |
---|
185 | - Latest upstream release |
---|
186 | - Remove python-nose-0.9.2-mandir.patch |
---|
187 | |
---|
188 | * Sat Mar 3 2007 Luke Macken <lmacken@redhat.com> 0.9.2-1 |
---|
189 | - Add nosetests(1) manpage, and python-nose-0.9.2-mandir.patch to put it in |
---|
190 | the correct location. |
---|
191 | - 0.9.2 |
---|
192 | |
---|
193 | * Sat Dec 9 2006 Luke Macken <lmacken@redhat.com> 0.9.1-2 |
---|
194 | - Rebuild for python 2.5 |
---|
195 | |
---|
196 | * Fri Nov 24 2006 Luke Macken <lmacken@redhat.com> 0.9.1-1 |
---|
197 | - 0.9.1 |
---|
198 | |
---|
199 | * Fri Sep 8 2006 Luke Macken <lmacken@redhat.com> 0.9.0-1 |
---|
200 | - 0.9.0 |
---|
201 | |
---|
202 | * Wed Apr 19 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.8.7.2-1 |
---|
203 | - Initial RPM release |
---|