commit
3cc6b465ab
@ -0,0 +1 @@
|
|||||||
|
SOURCES/mocha-1.15.0-test.tar.gz
|
@ -0,0 +1 @@
|
|||||||
|
bba0b9172e2ba37922da8cf59a285453a3090d4c SOURCES/mocha-1.15.0-test.tar.gz
|
Binary file not shown.
@ -0,0 +1,34 @@
|
|||||||
|
From ae9fed4a9f2ef6267302494ae0edf515d4a8a921 Mon Sep 17 00:00:00 2001
|
||||||
|
From: James Mead <james@floehopper.org>
|
||||||
|
Date: Thu, 24 Nov 2022 13:26:15 +0000
|
||||||
|
Subject: [PATCH] DRY up regexp_matches test
|
||||||
|
|
||||||
|
---
|
||||||
|
test/unit/parameter_matchers/regexp_matches_test.rb | 8 ++++++--
|
||||||
|
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/test/unit/parameter_matchers/regexp_matches_test.rb b/test/unit/parameter_matchers/regexp_matches_test.rb
|
||||||
|
index e0282c859..058baaccd 100644
|
||||||
|
--- a/test/unit/parameter_matchers/regexp_matches_test.rb
|
||||||
|
+++ b/test/unit/parameter_matchers/regexp_matches_test.rb
|
||||||
|
@@ -32,14 +32,18 @@ def test_should_not_match_on_empty_arguments
|
||||||
|
end
|
||||||
|
|
||||||
|
def test_should_not_raise_error_on_argument_that_does_not_respond_to_equals_tilde
|
||||||
|
- object_not_responding_to_equals_tilde = Class.new { undef =~ }.new
|
||||||
|
matcher = regexp_matches(/oo/)
|
||||||
|
assert_nothing_raised { matcher.matches?([object_not_responding_to_equals_tilde]) }
|
||||||
|
end
|
||||||
|
|
||||||
|
def test_should_not_match_on_argument_that_does_not_respond_to_equals_tilde
|
||||||
|
- object_not_responding_to_equals_tilde = Class.new { undef =~ }.new
|
||||||
|
matcher = regexp_matches(/oo/)
|
||||||
|
assert !matcher.matches?([object_not_responding_to_equals_tilde])
|
||||||
|
end
|
||||||
|
+
|
||||||
|
+ private
|
||||||
|
+
|
||||||
|
+ def object_not_responding_to_equals_tilde
|
||||||
|
+ Class.new { undef =~ }.new
|
||||||
|
+ end
|
||||||
|
end
|
@ -0,0 +1,27 @@
|
|||||||
|
From 26b106a540ad57cd73401461451aa2711c541e9d Mon Sep 17 00:00:00 2001
|
||||||
|
From: James Mead <james@floehopper.org>
|
||||||
|
Date: Fri, 25 Nov 2022 09:04:43 +0000
|
||||||
|
Subject: [PATCH] Fix regexp_matches tests in Ruby v3.2
|
||||||
|
|
||||||
|
Object#~= has been removed from Ruby v3.2 [1].
|
||||||
|
|
||||||
|
Closes #590.
|
||||||
|
|
||||||
|
[1]: https://bugs.ruby-lang.org/issues/15231
|
||||||
|
---
|
||||||
|
.circleci/config.yml | 1 +
|
||||||
|
test/unit/parameter_matchers/regexp_matches_test.rb | 2 +-
|
||||||
|
2 files changed, 2 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/test/unit/parameter_matchers/regexp_matches_test.rb b/test/unit/parameter_matchers/regexp_matches_test.rb
|
||||||
|
index 058baacc..20fb7c7c 100644
|
||||||
|
--- a/test/unit/parameter_matchers/regexp_matches_test.rb
|
||||||
|
+++ b/test/unit/parameter_matchers/regexp_matches_test.rb
|
||||||
|
@@ -44,6 +44,6 @@ def test_should_not_match_on_argument_that_does_not_respond_to_equals_tilde
|
||||||
|
private
|
||||||
|
|
||||||
|
def object_not_responding_to_equals_tilde
|
||||||
|
- Class.new { undef =~ }.new
|
||||||
|
+ Class.new { undef =~ if respond_to?(:=~) }.new
|
||||||
|
end
|
||||||
|
end
|
@ -0,0 +1,225 @@
|
|||||||
|
%global gem_name mocha
|
||||||
|
|
||||||
|
Name: rubygem-%{gem_name}
|
||||||
|
Version: 1.15.0
|
||||||
|
Release: 3%{?dist}
|
||||||
|
Summary: Mocking and stubbing library
|
||||||
|
License: MIT or Ruby or BSD
|
||||||
|
URL: https://mocha.jamesmead.org
|
||||||
|
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
||||||
|
# git clone https://github.com/freerange/mocha.git && cd mocha
|
||||||
|
# git archive -v -o mocha-1.15.0-test.tar.gz v1.15.0 test/
|
||||||
|
Source1: %{gem_name}-%{version}-test.tar.gz
|
||||||
|
# https://github.com/freerange/mocha/commit/ae9fed4a9f2ef6267302494ae0edf515d4a8a921
|
||||||
|
# To apply Patch1 cleanly:
|
||||||
|
Patch0: %{name}-2.0.2-dry-up-regexp-test.patch
|
||||||
|
# https://github.com/freerange/mocha/issues/590
|
||||||
|
# https://github.com/freerange/mocha/commit/26b106a540ad57cd73401461451aa2711c541e9d
|
||||||
|
# Fix regexp test, ruby3.2 removes Object#=~
|
||||||
|
Patch1: %{name}-2.0.2-ruby32-fix-regexp-test.patch
|
||||||
|
BuildRequires: ruby(release)
|
||||||
|
BuildRequires: rubygems-devel
|
||||||
|
BuildRequires: ruby
|
||||||
|
#BuildRequires: rubygem(metaclass)
|
||||||
|
BuildRequires: rubygem(introspection)
|
||||||
|
BuildRequires: rubygem(minitest)
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%description
|
||||||
|
Mocking and stubbing library with JMock/SchMock syntax, which allows mocking
|
||||||
|
and stubbing of methods on real (non-mock) classes.
|
||||||
|
|
||||||
|
|
||||||
|
%package doc
|
||||||
|
Summary: Documentation for %{name}
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%description doc
|
||||||
|
Documentation for %{name}.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q -n %{gem_name}-%{version} -b 1
|
||||||
|
(
|
||||||
|
cd %{_builddir}/test
|
||||||
|
%patch0 -p2
|
||||||
|
%patch1 -p2
|
||||||
|
)
|
||||||
|
|
||||||
|
%build
|
||||||
|
gem build ../%{gem_name}-%{version}.gemspec
|
||||||
|
%gem_install
|
||||||
|
|
||||||
|
%install
|
||||||
|
mkdir -p %{buildroot}%{gem_dir}
|
||||||
|
cp -a .%{gem_dir}/* \
|
||||||
|
%{buildroot}%{gem_dir}/
|
||||||
|
|
||||||
|
%check
|
||||||
|
pushd .%{gem_instdir}
|
||||||
|
ln -s %{_builddir}/test .
|
||||||
|
# Each part of test suite must be run separately, otherwise the test suite fails.
|
||||||
|
# https://github.com/freerange/mocha/issues/121
|
||||||
|
for kind in unit acceptance integration; do
|
||||||
|
ruby -e "Dir.glob('./test/$kind/**/*_test.rb').each {|t| require t}"
|
||||||
|
done
|
||||||
|
popd
|
||||||
|
|
||||||
|
%files
|
||||||
|
%exclude %{gem_instdir}/.*
|
||||||
|
%license %{gem_instdir}/COPYING.md
|
||||||
|
%license %{gem_instdir}/MIT-LICENSE.md
|
||||||
|
%exclude %{gem_instdir}/init.rb
|
||||||
|
%{gem_libdir}
|
||||||
|
%exclude %{gem_cache}
|
||||||
|
%{gem_spec}
|
||||||
|
|
||||||
|
%files doc
|
||||||
|
%doc %{gem_docdir}
|
||||||
|
%doc %{gem_instdir}/CONTRIBUTING.md
|
||||||
|
%{gem_instdir}/Gemfile
|
||||||
|
%doc %{gem_instdir}/README.md
|
||||||
|
%doc %{gem_instdir}/RELEASE.md
|
||||||
|
%{gem_instdir}/Rakefile
|
||||||
|
%{gem_instdir}/mocha.gemspec
|
||||||
|
%{gem_instdir}/gemfiles/
|
||||||
|
%{gem_instdir}/yard-templates/
|
||||||
|
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Thu Sep 21 2023 Arkady L. Shane <tigro@msvsphere-os.ru> - 1.15.0-3
|
||||||
|
- Rebuilt for MSVSphere 9.2
|
||||||
|
|
||||||
|
* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.15.0-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
||||||
|
|
||||||
|
* Sat Nov 26 2022 Mamoru TASAKA <mtasaka@fedoraproject.org> - 1.15.0-2
|
||||||
|
- Backport upstream fix for ruby3.2 Object#=~ removal
|
||||||
|
|
||||||
|
* Tue Oct 11 2022 Vít Ondruch <vondruch@redhat.com> - 1.15.0-1
|
||||||
|
- Update to Mocha 1.1.0.
|
||||||
|
Resolves: rhbz#1778907
|
||||||
|
|
||||||
|
* Sat Jul 23 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.0-7
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.0-6
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.0-5
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.0-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.0-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Oct 09 2019 Pavel Valena <pvalena@redhat.com> - 1.9.0-1
|
||||||
|
- Update to mocha 1.9.0.
|
||||||
|
|
||||||
|
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-9
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||||
|
|
||||||
|
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-8
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||||
|
|
||||||
|
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-7
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-6
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-5
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||||
|
|
||||||
|
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
||||||
|
|
||||||
|
* Mon Jul 07 2014 Vít Ondruch <vondruch@redhat.com> - 1.1.0-1
|
||||||
|
- Update to Mocha 1.1.0.
|
||||||
|
|
||||||
|
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.14.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Aug 15 2013 Ken Dreyer <ktdreyer@ktdreyer.com> - 0.14.0-1
|
||||||
|
- Update to 0.14.0
|
||||||
|
- Run unit and acceptance tests in a single process
|
||||||
|
- Patch test suite to work outside rake/bundler
|
||||||
|
|
||||||
|
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.13.1-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
||||||
|
|
||||||
|
* Mon Feb 25 2013 Vít Ondruch <vondruch@redhat.com> - 0.13.1-3
|
||||||
|
- Rebuild for https://fedoraproject.org/wiki/Features/Ruby_2.0.0
|
||||||
|
|
||||||
|
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.13.1-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Jan 02 2013 Vít Ondruch <vondruch@redhat.com> - 0.13.1-1
|
||||||
|
- Updated to the Mocha 0.13.1.
|
||||||
|
|
||||||
|
* Mon Jul 23 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 0.12.1-1
|
||||||
|
- Update to Mocha 0.12.1, as this version is needed by ActionPack 3.2.6 tests.
|
||||||
|
|
||||||
|
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.11.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Apr 19 2012 Vít Ondruch <vondruch@redhat.com> - 0.11.0-1
|
||||||
|
- Updated to the Mocha 0.11.0.
|
||||||
|
|
||||||
|
* Thu Jan 19 2012 Vít Ondruch <vondruch@redhat.com> - 0.10.0-3
|
||||||
|
- Rebuild for Ruby 1.9.3.
|
||||||
|
|
||||||
|
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.10.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||||
|
|
||||||
|
* Mon Oct 03 2011 Vít Ondruch <vondruch@redhat.com> - 0.10.0-1
|
||||||
|
- Updated to the Mocha 0.10.0.
|
||||||
|
|
||||||
|
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.8-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
||||||
|
|
||||||
|
* Sun Aug 29 2010 Michael Stahnke <stahnma@fedoraproject.org> - 0.9.8-1
|
||||||
|
- Fixed odd naming in BR
|
||||||
|
- Updating to 0.9.8
|
||||||
|
- Breaking into -doc package as well
|
||||||
|
- Adding tests
|
||||||
|
|
||||||
|
* Thu Jul 23 2009 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.7-1
|
||||||
|
- New upstream version
|
||||||
|
|
||||||
|
* Mon Apr 27 2009 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.5-1
|
||||||
|
- New upstream version
|
||||||
|
|
||||||
|
* Sun Feb 01 2009 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.1-4
|
||||||
|
- Mark files as %%doc
|
||||||
|
|
||||||
|
* Thu Oct 30 2008 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.1-3
|
||||||
|
- Use gem instead of tgz
|
||||||
|
|
||||||
|
* Sat Oct 25 2008 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.1-2
|
||||||
|
- Fix license
|
||||||
|
|
||||||
|
* Sat Oct 25 2008 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.1-1
|
||||||
|
- New upstream version
|
||||||
|
- Fix license not being marked as %%doc
|
||||||
|
|
||||||
|
* Mon Sep 08 2008 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.0-2
|
||||||
|
- Add ruby(abi) = 1.8 requirement
|
||||||
|
|
||||||
|
* Sat Aug 23 2008 Jeroen van Meeuwen <kanarip@fedoraproject.org> - 0.9.0-1
|
||||||
|
- New upstream version
|
||||||
|
- Initial package for review
|
||||||
|
|
||||||
|
* Sun Jul 13 2008 root <root@oss1-repo.usersys.redhat.com> - 0.5.6-1
|
||||||
|
- Initial package
|
Loading…
Reference in new issue