]> git.pld-linux.org Git - packages/python-testtools.git/blob - python-testtools.spec
- package testresult
[packages/python-testtools.git] / python-testtools.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # do not perform "make test"
4
5 Summary:        Extensions to the Python unit testing framework
6 Name:           python-testtools
7 Version:        0.9.15
8 Release:        3
9 License:        MIT
10 Group:          Development/Tools
11 URL:            https://launchpad.net/testtools
12 Source0:        http://pypi.python.org/packages/source/t/testtools/testtools-%{version}.tar.gz
13 # Source0-md5:  01a30afb126de49de4998c255259d312
14 BuildRequires:  python-Sphinx
15 BuildRequires:  python-devel
16 BuildRequires:  rpmbuild(macros) >= 1.219
17 BuildRequires:  sphinx-pdg
18 BuildArch:      noarch
19 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21 %description
22 testtools is a set of extensions to the Python standard library's unit
23 testing framework.
24
25 %package doc
26 Summary:        Documentation for %{name}
27 Group:          Documentation
28 Requires:       %{name} = %{version}-%{release}
29
30 %description doc
31 This package contains HTML documentation for %{name}.
32
33 %prep
34 %setup -q -n testtools-%{version}
35
36 %build
37 %{__python} setup.py build
38 %{__make} -C doc html
39
40 %if %{with tests}
41 %{__python} setup.py test
42 %endif
43
44 %install
45 rm -rf $RPM_BUILD_ROOT
46 %{__python} setup.py install \
47         -O2 \
48         --skip-build \
49         --root $RPM_BUILD_ROOT
50
51 %{__rm} -r $RPM_BUILD_ROOT%{py_sitescriptdir}/testtools/tests
52
53 %py_postclean
54
55 %clean
56 rm -rf $RPM_BUILD_ROOT
57
58 %files
59 %defattr(644,root,root,755)
60 %doc LICENSE NEWS README
61 %dir %{py_sitescriptdir}/testtools
62 %{py_sitescriptdir}/testtools/*.py[co]
63 %{py_sitescriptdir}/testtools-*.egg-info
64 %dir %{py_sitescriptdir}/testtools/testresult
65 %{py_sitescriptdir}/testtools/testresult/*.py[co]
66
67 %files doc
68 %defattr(644,root,root,755)
69 %doc doc/_build/html/*
This page took 0.082454 seconds and 4 git commands to generate.