diff --git a/.gitignore b/.gitignore index b2b3d2b..a631f4f 100644 --- a/.gitignore +++ b/.gitignore @@ -30,3 +30,5 @@ /rubygem-rspec-mocks-3.6.0-full.tar.gz /rspec-mocks-3.7.0.gem /rubygem-rspec-mocks-3.7.0-full.tar.gz +/rspec-mocks-3.8.0.gem +/rubygem-rspec-mocks-3.8.0-full.tar.gz diff --git a/rspec-mocks-3.7.0-test-ruby-25.patch b/rspec-mocks-3.7.0-test-ruby-25.patch deleted file mode 100644 index 240ea91..0000000 --- a/rspec-mocks-3.7.0-test-ruby-25.patch +++ /dev/null @@ -1,66 +0,0 @@ -From 871eb31e3bfe50705ca57e754771aa1e0164f12d Mon Sep 17 00:00:00 2001 -From: Myron Marston -Date: Sat, 30 Dec 2017 17:45:43 -0800 -Subject: [PATCH 1/2] Skip spec that does not apply to Ruby 2.5. - -Ruby 2.5 has removed the ability to access top-level constants -via a confusing nested form (e.g. `MyClass::Hash`), so we no -longer need this spec there. - -For #1192. ---- - spec/rspec/mocks/mutate_const_spec.rb | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/spec/rspec/mocks/mutate_const_spec.rb b/spec/rspec/mocks/mutate_const_spec.rb -index fe8d4128..9d80dd73 100644 ---- a/spec/rspec/mocks/mutate_const_spec.rb -+++ b/spec/rspec/mocks/mutate_const_spec.rb -@@ -170,7 +170,7 @@ def change_const_value_to(value) - expect(::Hash).to equal(top_level_hash) - end - -- it 'does not affect the ability to access the top-level constant from nested contexts', :silence_warnings do -+ it 'does not affect the ability to access the top-level constant from nested contexts', :silence_warnings, :if => RUBY_VERSION < '2.5' do - top_level_hash = ::Hash - - hide_const("TestClass::Hash") - -From 783923d6879a2f9df9fee8ef24cecca6ac21136e Mon Sep 17 00:00:00 2001 -From: Myron Marston -Date: Sat, 30 Dec 2017 23:35:27 -0800 -Subject: [PATCH 2/2] Make spec less brittle. - -On Ruby 2.5, this spec failed, apparently due to the fact that -Method equality has changed on 2.5 slightly. The method instances -have always been different but 2.4 and before considered them -equivalent. Instead, we can show that the two method objects -_behave_ the same, which is what we really care about. - -Fixes #1192. ---- - spec/rspec/mocks/and_wrap_original_spec.rb | 9 +++++---- - 1 file changed, 5 insertions(+), 4 deletions(-) - -diff --git a/spec/rspec/mocks/and_wrap_original_spec.rb b/spec/rspec/mocks/and_wrap_original_spec.rb -index df9cae46..2d4d0a8b 100644 ---- a/spec/rspec/mocks/and_wrap_original_spec.rb -+++ b/spec/rspec/mocks/and_wrap_original_spec.rb -@@ -26,12 +26,13 @@ def results - }.to raise_error NameError - end - -- it "passes in the original method" do -- value = nil -+ it "passes along the original method" do -+ passed_method = nil - original_method = instance.method(:results) -- allow_it.to receive(:results).and_wrap_original { |m| value = m } -+ allow_it.to receive(:results).and_wrap_original { |m| passed_method = m } - instance.results -- expect(value).to eq original_method -+ -+ expect(passed_method.call).to eq(original_method.call) - end - - it "passes along the message arguments" do diff --git a/rubygem-rspec-mocks.spec b/rubygem-rspec-mocks.spec index 2ea98c5..6a791c2 100644 --- a/rubygem-rspec-mocks.spec +++ b/rubygem-rspec-mocks.spec @@ -1,9 +1,9 @@ -%global majorver 3.7.0 +%global majorver 3.8.0 #%%global preminorver .rc6 %global rpmminorver .%(echo %preminorver | sed -e 's|^\\.\\.*||') %global fullver %{majorver}%{?preminorver} -%global fedorarel 3 +%global fedorarel 0.1 %global gem_name rspec-mocks @@ -14,7 +14,7 @@ Summary: RSpec's 'test double' framework (mocks and stubs) Name: rubygem-%{gem_name} Version: %{majorver} -Release: %{?preminorver:0.}%{fedorarel}%{?preminorver:%{rpmminorver}}%{?dist}.2 +Release: %{?preminorver:0.}%{fedorarel}%{?preminorver:%{rpmminorver}}%{?dist} Group: Development/Languages License: MIT @@ -23,9 +23,6 @@ Source0: https://rubygems.org/gems/%{gem_name}-%{fullver}.gem # %%{SOURCE2} %%{name} %%{version} Source1: rubygem-%{gem_name}-%{version}-full.tar.gz Source2: rspec-related-create-full-tarball.sh -# https://github.com/rspec/rspec-mocks/pull/1196 -# https://github.com/rspec/rspec-mocks/commit/1d2f2404a17c3a76742379bb0c57d133df8e7371.patch -Patch1: rspec-mocks-3.7.0-test-ruby-25.patch #BuildRequires: ruby(release) BuildRequires: rubygems-devel @@ -53,7 +50,6 @@ This package contains documentation for %{name}. gem unpack %{SOURCE0} %setup -q -D -T -n %{gem_name}-%{version} -b 1 -%patch1 -p1 gem specification %{SOURCE0} -l --ruby > %{gem_name}.gemspec @@ -92,6 +88,10 @@ ruby -rrubygems -Ilib/ -S rspec spec/ %{gem_docdir} %changelog +* Wed Dec 12 2018 Mamoru TASAKA - 3.8.0-0.1 +- 3.8.0 +- Once disable test for bootstrap + * Sun Nov 18 2018 Zbigniew Jędrzejewski-Szmek - 3.7.0-3.2 - Use C.UTF-8 locale See https://fedoraproject.org/wiki/Changes/Remove_glibc-langpacks-all_from_buildroot diff --git a/sources b/sources index 5950cd3..2f8578d 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (rspec-mocks-3.7.0.gem) = a1bd5992528adca3c9021fbc7afd9bfd43707e13c5f54879c9b603376c69fd23389b0c503912b76e10f42ed49b8ba23656220cc75869cc63bd5920efca667678 -SHA512 (rubygem-rspec-mocks-3.7.0-full.tar.gz) = adb947206ae5ba5154a151f794cc04cf6c901543a53998b78d7ba27848261b2b709322f46e2180572de7c5f5a3e34503eca8bd457e874c237f7fd18247ff7cda +SHA512 (rspec-mocks-3.8.0.gem) = 00b3b414cc47bc987db76c03f69a88ecb12960c74c3715fcd9a7be0562cf282cbd458709888d0f3718fb03997c7b74816677eae1310b0ac6f215467ede49e89e +SHA512 (rubygem-rspec-mocks-3.8.0-full.tar.gz) = 0c81e146aefb824b817cbb0229450866703dfd2b300b6bd8ad4d239faa05e8c0bc779f85541c04d19e555500e890c4a77bac19bc4d17726aee4fe1a52cece023