python-avocado.spec 15.0 KB
Newer Older
1
%global srcname avocado
2
%if ! 0%{?commit:1}
C
Cleber Rosa 已提交
3
 %define commit f12f277434096dc628f5b0b731d7c37e0789427d
4 5 6
%endif
%global shortcommit %(c=%{commit}; echo ${c:0:7})

7
Summary: Framework with tools and libraries for Automated Testing
8
Name: python-%{srcname}
C
Cleber Rosa 已提交
9
Version: 47.0
10
Release: 2%{?dist}
11 12
License: GPLv2
Group: Development/Tools
13
URL: http://avocado-framework.github.io/
14
Source0: https://github.com/avocado-framework/%{srcname}/archive/%{commit}/%{srcname}-%{version}-%{shortcommit}.tar.gz
15
BuildArch: noarch
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41
BuildRequires: fabric
BuildRequires: libvirt-python
BuildRequires: perl-Test-Harness
BuildRequires: procps-ng
BuildRequires: pystache
BuildRequires: python-docutils
BuildRequires: python-flexmock
BuildRequires: python-lxml
BuildRequires: python-mock
BuildRequires: python-psutil
BuildRequires: python-requests
BuildRequires: python-setuptools
BuildRequires: python-sphinx
BuildRequires: python-stevedore
BuildRequires: python-yaml
BuildRequires: python2-devel
BuildRequires: yum
Requires: gdb
Requires: gdb-gdbserver
Requires: procps-ng
Requires: pyliblzma
Requires: python
Requires: python-requests
Requires: python-setuptools
Requires: python-stevedore
Requires: python-yaml
42 43 44 45 46
%if 0%{?fedora}
BuildRequires: python-aexpect
%else
BuildRequires: aexpect
%endif
47

48 49 50 51 52 53 54 55 56
# For compatibility reasons, let's mark this package as one that
# provides the same functionality as the old package name and also
# one that obsoletes the old package name, so that the new name is
# favored.  These could (and should) be removed in the future.
# These changes are backed by the following guidelines:
# https://fedoraproject.org/wiki/Upgrade_paths_%E2%80%94_renaming_or_splitting_packages
Obsoletes: %{srcname} < 47.0-1
Provides: %{srcname} = %{version}-%{release}

57 58 59 60 61 62 63 64 65
# For some strange reason, fabric on Fedora 24 does not require the
# python-crypto package, but the fabric code always imports it.  Newer
# fabric versions, such from Fedora 25 do conditional imports (try:
# from Crypto import Random; except: Random = None) and thus do not
# need this requirement.
%if 0%{?fedora} == 24
BuildRequires: python-crypto
%endif

66 67 68 69 70 71 72
%if 0%{?fedora} >= 25
BuildRequires: kmod
%endif
%if 0%{?rhel} >= 7
BuildRequires: kmod
%endif

73
%description
74 75
Avocado is a set of tools and libraries (what people call
these days a framework) to perform automated testing.
76 77

%prep
78
%setup -q -n %{srcname}-%{commit}
79 80 81 82
# package plugins-runner-vm requires libvirt-python, but the RPM
# version of libvirt-python does not publish the egg info and this
# causes that dep to be attempted to be installed by pip
sed -e "s/'libvirt-python'//" -i optional_plugins/runner_vm/setup.py
83 84 85

%build
%{__python} setup.py build
86
pushd optional_plugins/html
87
%{__python} setup.py build
88 89
popd
pushd optional_plugins/runner_remote
90
%{__python} setup.py build
91 92
popd
pushd optional_plugins/runner_vm
93
%{__python} setup.py build
94 95
popd
pushd optional_plugins/runner_docker
96
%{__python} setup.py build
97
popd
98
%{__make} man
99 100 101

%install
%{__python} setup.py install --root %{buildroot} --skip-build
102
pushd optional_plugins/html
103
%{__python} setup.py install --root %{buildroot} --skip-build
104 105
popd
pushd optional_plugins/runner_remote
106
%{__python} setup.py install --root %{buildroot} --skip-build
107 108
popd
pushd optional_plugins/runner_vm
109
%{__python} setup.py install --root %{buildroot} --skip-build
110 111
popd
pushd optional_plugins/runner_docker
112
%{__python} setup.py install --root %{buildroot} --skip-build
113
popd
C
Cleber Rosa 已提交
114 115
%{__mkdir} -p %{buildroot}%{_mandir}/man1
%{__install} -m 0644 man/avocado.1 %{buildroot}%{_mandir}/man1/avocado.1
116
%{__install} -m 0644 man/avocado-rest-client.1 %{buildroot}%{_mandir}/man1/avocado-rest-client.1
117

118
%check
119
%{__python} setup.py develop --user
120
pushd optional_plugins/html
121
%{__python} setup.py develop --user
122 123
popd
pushd optional_plugins/runner_remote
124
%{__python} setup.py develop --user
125 126
popd
pushd optional_plugins/runner_vm
127
%{__python} setup.py develop --user
128 129
popd
pushd optional_plugins/runner_docker
130
%{__python} setup.py develop --user
131
popd
132
selftests/run
133

134 135 136 137
%files
%defattr(-,root,root,-)
%doc README.rst LICENSE
%dir /etc/avocado
138
%dir /etc/avocado/conf.d
139
%dir /etc/avocado/sysinfo
140 141
%dir /etc/avocado/scripts/job/pre.d
%dir /etc/avocado/scripts/job/post.d
142
%config(noreplace)/etc/avocado/avocado.conf
143
%config(noreplace)/etc/avocado/conf.d/README
144
%config(noreplace)/etc/avocado/conf.d/gdb.conf
145 146 147
%config(noreplace)/etc/avocado/sysinfo/commands
%config(noreplace)/etc/avocado/sysinfo/files
%config(noreplace)/etc/avocado/sysinfo/profilers
148 149
%config(noreplace)/etc/avocado/scripts/job/pre.d/README
%config(noreplace)/etc/avocado/scripts/job/post.d/README
150
%{python_sitelib}/avocado*
151
%{_bindir}/avocado
152
%{_bindir}/avocado-rest-client
C
Cleber Rosa 已提交
153
%{_mandir}/man1/avocado.1.gz
154
%{_mandir}/man1/avocado-rest-client.1.gz
155 156
%{_docdir}/avocado/avocado.rst
%{_docdir}/avocado/avocado-rest-client.rst
157
%exclude %{python_sitelib}/avocado_result_html*
158 159 160
%exclude %{python_sitelib}/avocado_runner_remote*
%exclude %{python_sitelib}/avocado_runner_vm*
%exclude %{python_sitelib}/avocado_runner_docker*
161 162 163 164 165
%{_libexecdir}/avocado/avocado-bash-utils
%{_libexecdir}/avocado/avocado_debug
%{_libexecdir}/avocado/avocado_error
%{_libexecdir}/avocado/avocado_info
%{_libexecdir}/avocado/avocado_warn
166

167 168
%package plugins-output-html
Summary: Avocado HTML report plugin
169 170 171
Requires: %{name} == %{version}, pystache
Obsoletes: %{srcname}-plugins-output-html < 47.0-1
Provides: %{srcname}-plugins-output-html = %{version}-%{release}
172 173 174 175 176 177 178

%description plugins-output-html
Adds to avocado the ability to generate an HTML report at every job results
directory. It also gives the user the ability to write a report on an
arbitrary filesystem location.

%files plugins-output-html
179
%{python_sitelib}/avocado_result_html*
180

181 182
%package plugins-runner-remote
Summary: Avocado Runner for Remote Execution
183 184
Requires: %{name} == %{version}
Requires: fabric
185 186 187 188
%if 0%{?fedora} == 24
Requires: python-crypto
BuildRequires: python-crypto
%endif
189 190
Obsoletes: %{srcname}-plugins-runner-remote < 47.0-1
Provides: %{srcname}-plugins-runner-remote = %{version}-%{release}
191 192 193 194 195 196 197 198 199 200

%description plugins-runner-remote
Allows Avocado to run jobs on a remote machine, by means of an SSH
connection.  Avocado must be previously installed on the remote machine.

%files plugins-runner-remote
%{python_sitelib}/avocado_runner_remote*

%package plugins-runner-vm
Summary: Avocado Runner for libvirt VM Execution
201 202
Requires: %{name} == %{version}
Requires: %{name}-plugins-runner-remote == %{version}
203
Requires: libvirt-python
204 205
Obsoletes: %{srcname}-plugins-runner-vm < 47.0-1
Provides: %{srcname}-plugins-runner-vm = %{version}-%{release}
206 207 208 209 210 211 212 213 214 215 216

%description plugins-runner-vm
Allows Avocado to run jobs on a libvirt based VM, by means of
interaction with a libvirt daemon and an SSH connection to the VM
itself.  Avocado must be previously installed on the VM.

%files plugins-runner-vm
%{python_sitelib}/avocado_runner_vm*

%package plugins-runner-docker
Summary: Avocado Runner for Execution on Docker Containers
217 218
Requires: %{name} == %{version}
Requires: %{name}-plugins-runner-remote == %{version}
219 220 221 222 223
%if 0%{?fedora}
Requires: python-aexpect
%else
Requires: aexpect
%endif
224 225
Obsoletes: %{srcname}-plugins-runner-docker < 47.0-1
Provides: %{srcname}-plugins-runner-docker = %{version}-%{release}
226 227 228 229 230 231 232 233 234 235

%description plugins-runner-docker
Allows Avocado to run jobs on a Docker container by interacting with a
Docker daemon and attaching to the container itself.  Avocado must
be previously installed on the container.

%files plugins-runner-docker
%{python_sitelib}/avocado_runner_docker*


236
%package examples
237
Summary: Avocado Test Framework Example Tests
238
Requires: %{name} == %{version}
239

240 241 242 243
%description examples
The set of example tests present in the upstream tree of the Avocado framework.
Some of them are used as functional tests of the framework, others serve as
examples of how to write tests on your own.
244

245
%files examples
246
%{_datadir}/avocado/tests
247
%{_datadir}/avocado/wrappers
248 249

%changelog
250 251
* Fri Mar 31 2017 Cleber Rosa <cleber@redhat.com> - 47.0-2
- Switch directory change statements to match downstream
252
- Change requirements style to one per line
253

254 255 256
* Wed Mar  8 2017 Cleber Rosa <cleber@redhat.com> - 47.0-1
- Rename package to python-avocado and subpackges accordingly

C
Cleber Rosa 已提交
257 258 259
* Mon Mar  6 2017 Cleber Rosa <cleber@redhat.com> - 47.0-0
- New upstream release

260 261 262
* Wed Feb 15 2017 Cleber Rosa <cleber@redhat.com> - 46.0-2
- Removed python-crypto dependency from base avocado package

263 264 265 266 267
* Wed Feb 15 2017 Cleber Rosa <cleber@redhat.com> - 46.0-1
- Fixed packager email
- Added explicit requirement

* Tue Feb 14 2017 Cleber Rosa <cleber@redhat.com> - 46.0-0
C
Cleber Rosa 已提交
268 269
- New upstream release

270 271 272
* Sun Feb  5 2017 Cleber Rosa <cleber@redhat.com> - 45.0-2
- Split package into plugins-runner-{remote,vm,docker} packages

273 274 275
* Fri Feb  3 2017 Cleber Rosa <cleber@redhat.com> - 45.0-1
- Removed support for EL6 requirements

C
Cleber Rosa 已提交
276 277 278
* Tue Jan 17 2017 Cleber Rosa <cleber@redhat.com> - 45.0-0
- New upstream release

C
Cleber Rosa 已提交
279 280 281
* Wed Dec  7 2016 Cleber Rosa <cleber@redhat.com> - 44.0-0
- New upstream release

C
Cleber Rosa 已提交
282 283 284
* Tue Nov  8 2016 Cleber Rosa <cleber@redhat.com> - 43.0-0
- New upstream release

C
Cleber Rosa 已提交
285 286 287
* Mon Oct 10 2016 Cleber Rosa <cleber@redhat.com> - 42.0-0
- New upstream release

C
Cleber Rosa 已提交
288 289 290 291
* Fri Sep 16 2016 Cleber Rosa <cleber@redhat.com> - 41.0-1
- Consolidated build requires common to all targets
- Enabled check on EL6

C
Cleber Rosa 已提交
292 293 294
* Mon Sep 12 2016 Cleber Rosa <cleber@redhat.com> - 41.0-0
- New upstream release

295 296 297
* Tue Sep  6 2016 Cleber Rosa <cleber@redhat.com> - 40.0-1
- Adapt build of now separate html plugin

C
Cleber Rosa 已提交
298 299 300
* Tue Aug 16 2016 Cleber Rosa <cleber@redhat.com> - 40.0-0
- New upstream release

301 302 303
* Tue Aug  2 2016 Cleber Rosa <cleber@redhat.com> - 39.0-1
- Added expect requirement (for Docker plugin)

C
Cleber Rosa 已提交
304 305 306
* Tue Jul 26 2016 Cleber Rosa <cleber@redhat.com> - 39.0-0
- New upstream release

C
Cleber Rosa 已提交
307 308 309
* Mon Jul  4 2016 Cleber Rosa <cleber@redhat.com> - 38.0-0
- New upstream release

C
Cleber Rosa 已提交
310 311
* Tue Jun 14 2016 Cleber Rosa <cleber@redhat.com> - 37.0-0
- New upstream release
C
Cleber Rosa 已提交
312

313 314 315
* Thu May 05 2016 Amador Pahim <apahim@redhat.com> - 35.0-1
- Removed simpletests directory

C
Cleber Rosa 已提交
316 317 318
* Wed Apr 27 2016 Cleber Rosa <cleber@redhat.com> - 35.0-0
- New upstream release 35.0 (new versioning scheme)

319 320 321
* Thu Apr 14 2016 Cleber Rosa <cleber@redhat.com> - 0.34.0-1
- Added job pre/post scripts directories

322
* Mon Mar 21 2016 Cleber Rosa <cleber@redhat.com> - 0.34.0-0
C
Cleber Rosa 已提交
323 324
- New upstream release 0.34.0

325 326 327
* Wed Feb 17 2016 Cleber Rosa <cleber@redhat.com> - 0.33.0-1
- Updated requirement: procps for EL6, procps-ng for other distros

C
Cleber Rosa 已提交
328 329 330
* Tue Feb 16 2016 Cleber Rosa <cleber@redhat.com> - 0.33.0-0
- New upstream release 0.33.0

C
Cleber Rosa 已提交
331 332 333
* Wed Jan 20 2016 Cleber Rosa <cleber@redhat.com> - 0.32.0-0
- New upstream release 0.32.0

C
Cleber Rosa 已提交
334
* Wed Dec 23 2015 Cleber Rosa <cleber@redhat.com> - 0.31.0-0
C
Cleber Rosa 已提交
335
- New upstream release 0.31.0
C
Cleber Rosa 已提交
336

337 338 339
* Tue Nov 17 2015 Cleber Rosa <cleber@redhat.com> - 0.30.0-1
- Add python-stevedore to Requires

C
Cleber Rosa 已提交
340 341 342
* Thu Nov  5 2015 Cleber Rosa <cleber@redhat.com> - 0.30.0-0
- New upstream release 0.30.0

343 344 345
* Wed Oct 7 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.29.0-2
- Add python-setuptools to BuildRequires

L
Lucas Meneghel Rodrigues 已提交
346 347 348
* Wed Oct 7 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.29.0-1
- New upstream release 0.29.0

349 350 351
* Wed Sep 16 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.28.0-2
- Add pystache, aexpect, psutil, sphinx and yum/dnf dependencies for functional/unittests

352 353 354
* Wed Sep 16 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.28.0-1
- New upstream release 0.28.0

355 356 357
* Tue Aug 4 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.27.0-3
- Added 'gdb' and 'gdb-gdbserver' as requirements

358 359 360
* Mon Aug 3 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.27.0-2
- Added 'python-mock' as a build requirement

361 362 363
* Mon Aug 3 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.27.0-1
- New upstream release 0.27.0

364 365 366
* Mon Jul 6 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.26.0-1
- New upstream release 0.26.0

367 368 369
* Tue Jun 16 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.25.0-2
- Fix spec bug with BuildRequires on EPEL6

370 371 372
* Tue Jun 16 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.25.0-1
- New upstream release 0.25.0

373 374 375
* Fri Jun  5 2015 Cleber Rosa <cleber@redhat.com> - 0.24.0-3
- Removed rest client API examples

376 377 378
* Mon May 25 2015 Cleber Rosa <cleber@redhat.com> - 0.24.0-2
- Added previously missing gdb.conf

379 380 381
* Mon May 18 2015 Ruda Moura <rmoura@redhat.com> - 0.24.0-1
- Update to upstream version 0.24.0

382 383 384
* Tue Apr 21 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.23.0-1
- New upstream release

385 386 387
* Mon Apr 13 2015 Cleber Rosa <cleber@redhat.com> - 0.21.0-6
- Added sysinfo configuration files

388 389
* Sat Mar 28 2015 Cleber Rosa <cleber@redhat.com> - 0.21.0-5
- Change the way man pages are built, now using Makefile targets
390
- Reorganized runtime and build requirements
391
- Add a check section that runs unittests on Fedora
392

393 394 395 396 397 398 399 400 401 402 403 404 405 406 407
* Thu Mar 19 2015 Lucas Meneghel Rodrigues - 0.21.0-4
- COPR build fixes

* Mon Mar 16 2015 Lucas Meneghel Rodrigues - 0.21.0-3
- COPR build fixes

* Mon Mar 16 2015 Lucas Meneghel Rodrigues - 0.21.0-2
- COPR build fixes

* Mon Mar 16 2015 Lucas Meneghel Rodrigues - 0.21.0-1
- COPR build fixes

* Mon Mar 16 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.21.0-0
- Update to upstream version 0.21.0

408 409 410
* Mon Feb 23 2015 Cleber Rosa <cleber@redhat.com> - 0.20.1-2
- Added avocado-rest-client modules, script, man page and API examples

411 412 413
* Fri Feb 6 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.20.1-1
- Update to upstream version 0.20.1

414
* Tue Feb 3 2015 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.20.0-1
415 416
- Update to upstream version 0.20.0

417 418 419
* Mon Dec 15 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.17.0-1
- Update to upstream version 0.17.0

420 421 422
* Wed Dec  3 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.14.0-3
- Change config file name from settings.ini to avocado.conf

423 424 425
* Wed Dec  3 2014 Ruda Moura <rmoura@redhat.com> - 0.14.0-2
- Include all wrappers scripts to examples subpackage.

426 427 428
* Mon Oct 13 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.14.0-1
- New upstream release

429
* Thu Sep 11 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.12.0-2
430 431
- Rename -tests package to -examples

432 433 434
* Tue Sep  9 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.12.0-1
- New upstream release

435 436 437
* Tue Sep  2 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.11.1-2
- Added fabric dependency

438 439 440 441
* Wed Aug 20 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.11.1-1
- Bumped version to avocado 0.11.1
- Added python-yaml build dependency

442 443 444 445
* Wed Aug 20 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.11.0-1
- Bumped version to avocado 0.11.0
- Added python-yaml new dependency

C
Cleber Rosa 已提交
446 447 448
* Wed Aug 20 2014 Cleber Rosa <cleber@redhat.com> - 0.10.1-2
- Added initial avocado man page

449 450 451
* Tue Aug 12 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.10.1-1
- Bugfix release 0.10.1

452 453 454
* Thu Aug  7 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.10.0-1
- Bumped version to Avocado 0.10.0

455 456 457
* Wed Jul 30 2014 Cleber Rosa <cleber@redhat.com> - 0.8.0-2
- Split tests into avocado-tests package

458 459 460
* Fri Jul 18 2014 Lucas Meneghel Rodrigues <lmr@redhat.com> - 0.8.0-1
- Bumped version to Avocado 0.8.0

461 462 463
* Fri Jun 13 2014 Ruda Moura <rmoura@redhat.com> - 0.6.0-1
- Bumped version to Avocado 0.6.0

464 465 466
* Thu May  8 2014 Ruda Moura <rmoura@redhat.com> - 0.4.0-1
- Bumped version to Avocado 0.4.0

467 468 469
* Wed Apr 30 2014 Cleber Rosa <cleber@redhat.com> - 0.0.1-2
- Added new requirements reflecting new upstream deps

470 471
* Wed Apr  2 2014 Ruda Moura <rmoura@redhat.com> - 0.0.1-1
- Created initial spec file