]> git.pld-linux.org Git - packages/ruby-minitest.git/commitdiff
up to 4.7.0
authorElan Ruusamäe <glen@delfi.ee>
Sun, 14 Apr 2013 11:55:14 +0000 (14:55 +0300)
committerElan Ruusamäe <glen@delfi.ee>
Sun, 14 Apr 2013 11:55:14 +0000 (14:55 +0300)
ruby-minitest.spec

index bf2a373567315afcc6f07a18e3c2caf26e29b0ee..fd22b019cdf3fc47546d29b826f130e7f169eff2 100644 (file)
@@ -1,30 +1,30 @@
+#
+# Conditional build:
+%bcond_without tests           # build without tests
+
 %define pkgname minitest
-Summary:       Small and fast replacement for ruby's huge and slow test/unit.
+Summary:       Small and fast replacement for ruby's huge and slow test/unit
 Name:          ruby-%{pkgname}
-Version:       1.5.0
+Version:       4.7.0
 Release:       0.1
 License:       MIT/Ruby License
-Source0:       http://rubygems.org/downloads/%{pkgname}-%{version}.gem
-# Source0-md5: 02a8c9d1afe9a4952e5b8d6f2fc202d7
 Group:         Development/Languages
+Source0:       http://gems.rubyforge.org/gems/%{pkgname}-%{version}.gem
+# Source0-md5: 3f527181eb7a1e00c92d0088fff94525
 URL:           http://rubyforge.org/projects/bfts
-BuildRequires: rpmbuild(macros) >= 1.484
-BuildRequires: ruby >= 1:1.8.6
-BuildRequires: ruby-modules
-%{?ruby_mod_ver_requires_eq}
-#BuildArch:    noarch
+BuildRequires: rpm-rubyprov
+BuildRequires: rpmbuild(macros) >= 1.656
+BuildArch:     noarch
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-# nothing to be placed there. we're not noarch only because of ruby packaging
-%define                _enable_debug_packages  0
-
 %description
 minitest/unit is a small and fast replacement for ruby's huge and slow
-test/unit. This is meant to be clean and easy to use both as a regular test
-writer and for language implementors that need a minimal set of methods to
-bootstrap a working unit test suite. mini/spec is a functionally complete spec
-engine. mini/mock, by Steven Baker, is a beautifully tiny mock object
-framework. (This package was called miniunit once upon a time)
+test/unit. This is meant to be clean and easy to use both as a regular
+test writer and for language implementors that need a minimal set of
+methods to bootstrap a working unit test suite. mini/spec is a
+functionally complete spec engine. mini/mock, by Steven Baker, is a
+beautifully tiny mock object framework. (This package was called
+miniunit once upon a time)
 
 %package rdoc
 Summary:       Documentation files for %{pkgname}
@@ -35,20 +35,31 @@ Requires:   ruby >= 1:1.8.7-4
 Documentation files for %{pkgname}.
 
 %prep
-%setup -q -c
-%{__tar} xf %{SOURCE0} -O data.tar.gz | %{__tar} xz
-find -newer README.txt  -o -print | xargs touch --reference %{SOURCE0}
+%setup -q -n %{pkgname}-%{version}
+
+find lib -type f | xargs sed -i -e '/^#!\/usr\/bin\/ruby.*/d'
 
 %build
+%if %{with tests}
+# spec test suite is unstable.
+# https://github.com/seattlerb/minitest/issues/257
+mv test/minitest/test_minitest_spec.rb{,.ignore}
+
+for f in test/minitest/test_*.rb; do
+       ruby -Ilib:.:./test $f
+done
+%endif
+
 rdoc --ri --op ri lib
 rdoc --op rdoc lib
-rm -rf ri/{Kernel,MockExpectationError,Module,Object,Test}
-rm -f ri/created.rid
+rm -rf ri/{PrideIO,ParallelEach,PrideLOL,Kernel,MockExpectationError,Module,Object,Test}
+rm ri/created.rid
+rm ri/cache.ri
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{ruby_rubylibdir},%{ruby_ridir},%{ruby_rdocdir}}
-cp -a lib/* $RPM_BUILD_ROOT%{ruby_rubylibdir}
+install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{ruby_ridir},%{ruby_rdocdir}}
+cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir}
 cp -a ri/* $RPM_BUILD_ROOT%{ruby_ridir}
 cp -a rdoc $RPM_BUILD_ROOT%{ruby_rdocdir}/%{name}-%{version}
 
@@ -58,9 +69,13 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(644,root,root,755)
 %doc History.txt README.txt
-%{ruby_rubylibdir}/%{pkgname}
+%dir %{ruby_vendorlibdir}/hoe
+%{ruby_vendorlibdir}/hoe/minitest.rb
+%{ruby_vendorlibdir}/minitest
 
 %files rdoc
 %defattr(644,root,root,755)
 %{ruby_rdocdir}/%{name}-%{version}
 %{ruby_ridir}/MiniTest
+%{ruby_ridir}/Minitest
+%{ruby_ridir}/Hoe
This page took 0.125134 seconds and 4 git commands to generate.