2020-08-20 17:18:08 +08:00
|
|
|
%global gem_name ZenTest
|
|
|
|
|
Name: rubygem-%{gem_name}
|
2022-05-17 17:31:05 +08:00
|
|
|
Version: 4.12.1
|
2023-06-01 19:02:03 +08:00
|
|
|
Release: 2
|
2020-08-20 17:18:08 +08:00
|
|
|
Summary: Automated test scaffolding for Ruby
|
|
|
|
|
License: MIT
|
|
|
|
|
URL: https://github.com/seattlerb/zentest
|
|
|
|
|
Source0: https://rubygems.org/gems/ZenTest-%{version}.gem
|
2023-06-01 19:02:03 +08:00
|
|
|
Patch0: Do-not-use-ruby-install-in-multiruby.patch
|
|
|
|
|
Patch1: fix-ZenTest-4.12.1.gemspec.patch
|
|
|
|
|
Patch2: fix-zentest-version.patch
|
2020-08-20 17:18:08 +08:00
|
|
|
BuildRequires: ruby(release) rubygems-devel rubygem(minitest)
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
%description
|
|
|
|
|
ZenTest is an automated test scaffolding for Ruby that provides 4 different
|
|
|
|
|
tools: zentest, unit_diff, autotest and multiruby. These tools can be used for
|
|
|
|
|
test conformance auditing and rapid XP.
|
|
|
|
|
|
|
|
|
|
%package doc
|
|
|
|
|
Summary: Documentation for %{name}
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
%description doc
|
|
|
|
|
Documentation for %{name}.
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -n %{gem_name}-%{version}
|
2023-06-01 19:02:03 +08:00
|
|
|
%patch0 -p1
|
|
|
|
|
%patch2 -p1
|
|
|
|
|
pushd ../
|
|
|
|
|
%patch1 -p0
|
|
|
|
|
popd
|
2020-08-20 17:18:08 +08:00
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
gem build ../%{gem_name}-%{version}.gemspec
|
|
|
|
|
%gem_install
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
mkdir -p %{buildroot}%{gem_dir}
|
|
|
|
|
cp -a .%{gem_dir}/* \
|
|
|
|
|
%{buildroot}%{gem_dir}/
|
|
|
|
|
mkdir -p %{buildroot}%{_bindir}
|
|
|
|
|
cp -a .%{_bindir}/* \
|
|
|
|
|
%{buildroot}%{_bindir}/
|
|
|
|
|
find %{buildroot}%{gem_instdir}/bin -type f | xargs chmod a+x
|
|
|
|
|
find %{buildroot}%{gem_instdir}/bin -type f | \
|
|
|
|
|
xargs -n 1 sed -i -e 's"^#!/usr/bin/env ruby"#!/usr/bin/ruby"'
|
|
|
|
|
find %{buildroot}%{gem_instdir}/test -type f | \
|
|
|
|
|
xargs -n 1 sed -i -e '/^#!\/usr\/.*\/ruby.*/d'
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
pushd .%{gem_instdir}
|
|
|
|
|
ruby -Ilib -e 'Dir.glob "./test/test_*.rb", &method(:require)'
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%dir %{gem_instdir}
|
|
|
|
|
%{_bindir}/multigem
|
|
|
|
|
%{_bindir}/multiruby
|
|
|
|
|
%{_bindir}/unit_diff
|
|
|
|
|
%{_bindir}/zentest
|
|
|
|
|
%exclude %{gem_instdir}/.*
|
|
|
|
|
%doc %{gem_instdir}/README.txt
|
|
|
|
|
%{gem_instdir}/bin
|
|
|
|
|
%{gem_libdir}
|
|
|
|
|
%exclude %{gem_cache}
|
|
|
|
|
%{gem_spec}
|
|
|
|
|
|
|
|
|
|
%files doc
|
|
|
|
|
%doc %{gem_docdir}
|
|
|
|
|
%doc %{gem_instdir}/History.txt
|
2022-05-17 17:31:05 +08:00
|
|
|
%{gem_instdir}/Rakefile
|
|
|
|
|
%doc %{gem_instdir}/Manifest.txt
|
2020-08-20 17:18:08 +08:00
|
|
|
%doc %{gem_instdir}/articles
|
|
|
|
|
%doc %{gem_instdir}/example*.rb
|
|
|
|
|
%doc %{gem_instdir}/example.txt
|
2022-05-17 17:31:05 +08:00
|
|
|
%{gem_instdir}/test
|
2020-08-20 17:18:08 +08:00
|
|
|
|
|
|
|
|
%changelog
|
2023-06-01 19:02:03 +08:00
|
|
|
* Thu Jun 1 2023 liyanan <thistleslyn@163.com> - 4.12.1-2
|
|
|
|
|
- Do not use ruby-install in multiruby
|
|
|
|
|
|
2022-05-17 17:31:05 +08:00
|
|
|
* Tue May 17 2022 liyanan <liyanan32@h-partners.com> - 4.12.1-1
|
|
|
|
|
- update to 4.12.1
|
|
|
|
|
|
2020-08-20 17:18:08 +08:00
|
|
|
* Fri Aug 7 2020 yanan li <liyanan032@huawei.com> - 4.11.2-1
|
|
|
|
|
- Package init
|