File zope-ZopeTestCase.spec of Package zope-ZopeTestCase

%define product   ZopeTestCase
%define version   0.9.8
%define release   2

%define zope_home %{_prefix}/lib/zope
%define software_home %{zope_home}/lib/python

Summary:   A unit test framework for Zope
Name:      zope-%{product}
Version:   %{version}
Release:   %{release}
License:   GPL
Group:     Development/Python
Source:    %{product}-%{version}.tar.bz2
URL:       http://zope.org/Members/shh/ZopeTestCase
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-rootdir
BuildArch: noarch
Requires:  zope >= 2.5

#----------------------------------------------------------------------
%description
ZopeTestCase is a unit testing framework and TestCase for Zope testing.
It is built on PyUnit and the Testing package shipping with Zope.

ZopeTestCase has features to support a wide range of test scenarios,
from small unit tests to running regression suites against existing
ZODBs. It supports testing in INSTANCE_HOME situations and is fully
testrunner compatible.

#----------------------------------------------------------------------
%prep
%setup -c

%build

%install
%{__rm} -rf %{buildroot}
%{__mkdir_p} %{buildroot}/%{software_home}/Testing
%{__cp} -a * %{buildroot}%{software_home}/Testing/


%clean
%{__rm} -rf %{buildroot}

%post
if [ "`%{_prefix}/bin/zopectl status`" != "daemon manager not running" ] ; then
  service zope restart
fi

%postun
if [ -f "%{_prefix}/bin/zopectl" ] && [ "`%{_prefix}/bin/zopectl status`" != "daemon manager not running" ] ; then
  service zope restart
fi

%files
%defattr(0644, zope, zope, 0755)
%{software_home}/Testing/*

#----------------------------------------------------------------------
%changelog
* Mon Jan 22 2007 Kevin Deldycke <kevin@nexedi.com> 0.9.8-2mdv2007.0
- Rebuild for Mandriva 2007.0

* Fri Feb 03 2006 Kevin Deldycke <kevin@nexedi.com> 0.9.8-1mdk
- Update to a newer version

* Wed Feb 01 2006 Kevin Deldycke <kevin@nexedi.com> 0.9.0-4mdk
- Give ownership to zope

* Tue Jan 31 2006 Kevin Deldycke <kevin@nexedi.com> 0.9.0-3mdk
- Update description

* Wed Jan 05 2006 Kevin Deldycke <kevin@nexedi.com> 0.9.0-2mdk
- Update spec file to follow new mandrake .spec file rules

* Wed Aug 18 2004 Sebastien Robin <seb@nexedi.com> 0.9.0-1mdk
- Create the spec file
openSUSE Build Service is sponsored by