From 04e0131e12eb88a6493b30ae9781fe650a8235f2 Mon Sep 17 00:00:00 2001 From: Troy Dawson Date: Fri, 20 Nov 2020 07:42:15 -0800 Subject: [PATCH] Make tests optional, No tests for RHEL --- rubygem-httpclient.spec | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/rubygem-httpclient.spec b/rubygem-httpclient.spec index 8ad7acf..451a931 100644 --- a/rubygem-httpclient.spec +++ b/rubygem-httpclient.spec @@ -2,18 +2,26 @@ %global rubyabi 1.8 +%if 0%{?rhel} +%bcond_with tests +%else +%bcond_without tests +%endif + + Summary: HTTP Client interface for ruby Name: rubygem-%{gem_name} Version: 2.8.3 -Release: 1%{?dist} +Release: 2%{?dist} License: (Ruby or BSD) and Public Domain URL: https://github.com/nahi/httpclient Source0: http://gems.rubyforge.org/gems/%{gem_name}-%{version}.gem Requires: ruby(release) -#BuildRequires: rubygem(minitest4) -BuildRequires: rubygem(test-unit) BuildRequires: rubygems-devel +%if %{with tests} +BuildRequires: rubygem(test-unit) BuildRequires: rubygem(http-cookie) +%endif BuildArch: noarch %description @@ -59,6 +67,7 @@ find %{buildroot}/%{gem_instdir} -type f -perm /g+wx -exec chmod -v g-w {} \; # Find files that are not readable find %{buildroot}/%{gem_instdir} -type f ! -perm /go+r -exec chmod -v go+r {} \; +%if %{with tests} %check pushd %{buildroot}%{gem_instdir} # All the tests in test_auth.rb were being bypassed @@ -81,6 +90,7 @@ ruby -Ilib -e 'Dir.glob "./test/test_*.rb", &method(:require)' -- \ --ignore-name /^test_debug_dev$/ \ --ignore-name /^test_ciphers$/ \ popd +%endif %files %dir %{gem_instdir} @@ -97,6 +107,13 @@ popd %changelog +* Fri Nov 20 2020 Troy Dawson - 2.8.3-2 +- Make tests optional +- No tests for RHEL + +* Wed Aug 05 2020 Troy Dawson - 2.8.3-1 +- Update to 2.8.3 + * Thu Jan 30 2020 Fedora Release Engineering - 2.8.0-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild