--- /dev/null
+%if 0%{?fedora} < 13 && 0%{?rhel} < 5
+%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
+%{!?python_version: %global python_version %(%{__python} -c "import sys ; print sys.version[:3]")}
+%endif
+
+%global upstream_name nose
+
+# Enable building without docs to avoid a circular dependency between this and python-sphinx
+%global with_docs 0
+
+Name: python-nose
+Version: 1.2.1
+Release: 0
+Summary: A discovery-based unittest extension for Python
+
+Group: Development/Languages
+License: LGPLv2+ and Public Domain
+URL: https://pypi.python.org/pypi/nose/
+Source0: https://pypi.python.org/pypi/nose/%{version}/nose-%{version}.tar.gz
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
+BuildArch: noarch
+BuildRequires: python-devel
+%if 0%{?fedora} && 0%{?fedora} < 13
+BuildRequires: python-setuptools-devel
+%else
+BuildRequires: python-setuptools
+%endif
+BuildRequires: dos2unix
+BuildRequires: python-coverage
+Requires: python-setuptools
+Requires: python-unittest2
+
+%description
+nose extends the test loading and running features of unittest, making
+it easier to write, find and run tests.
+
+By default, nose will run tests in files or directories under the
+current working directory whose names include "test" or "Test" at a
+word boundary (like "test_this" or "functional_test" or "TestClass"
+but not "libtest"). Test output is similar to that of unittest, but
+also includes captured stdout output from failing tests, for easy
+print-style debugging.
+
+These features, and many more, are customizable through the use of
+plugins. Plugins included with nose provide support for doctest, code
+coverage and profiling, flexible attribute-based test selection,
+output capture and more.
+
+%if 0%{?with_docs}
+%package docs
+Summary: Nose Documentation
+Group: Documentation
+BuildRequires: python-sphinx
+
+%description docs
+Documentation for Nose
+%endif # with_docs
+
+%prep
+%setup -q -n %{upstream_name}-%{version}
+
+dos2unix examples/attrib_plugin.py
+
+%build
+%{__python} setup.py build
+
+
+%install
+rm -rf %{buildroot}
+%{__python} setup.py install --skip-build --root %{buildroot} \
+ --install-data=%{_datadir}
+
+%if 0%{?with_docs}
+pushd doc
+make html
+]rm -rf .build/html/.buildinfo .build/html/_sources
+mv .build/html ..
+rm -rf .build
+popd
+cp -a doc reST
+%endif # with_docs
+
+
+
+%clean
+rm -rf %{buildroot}
+
+
+%files
+%defattr(-,root,root,-)
+%doc AUTHORS CHANGELOG lgpl.txt NEWS README.txt
+%{_bindir}/nosetests
+%{_bindir}/nosetests-%{python_version}
+%{_mandir}/man1/nosetests.1.gz
+%{python_sitelib}/nose*
+
+%if 0%{?with_docs}
+%files docs
+%defattr(-,root,root,-)
+%doc html reST examples
+%endif # with_docs
+
+%changelog