Compare commits
10 Commits
dbedb30ca8
...
d41dd27620
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d41dd27620 | ||
|
|
da9977c28e | ||
|
|
1302a223c2 | ||
|
|
8d6878b496 | ||
|
|
3e5628e3f3 | ||
|
|
f6ae10e83c | ||
|
|
aec73270ce | ||
|
|
0d14b60b5d | ||
|
|
ebe36e95fb | ||
|
|
e08e62987d |
BIN
0.1.5.tar.gz
Normal file
BIN
0.1.5.tar.gz
Normal file
Binary file not shown.
@ -0,0 +1,37 @@
|
||||
From 5891358639fcfa7a2e2004855275bd7da0c85c64 Mon Sep 17 00:00:00 2001
|
||||
From: James Coglan <jcoglan@gmail.com>
|
||||
Date: Sun, 6 Feb 2022 23:36:18 +0000
|
||||
Subject: [PATCH] As of rspec-mocks v3.10.3, mock expectations need to use
|
||||
explicit hashes to avoid confusion with keyword args
|
||||
|
||||
---
|
||||
spec/websocket/extensions_spec.rb | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/spec/websocket/extensions_spec.rb b/spec/websocket/extensions_spec.rb
|
||||
index 7c1e4f1..ccb305d 100644
|
||||
--- a/spec/websocket/extensions_spec.rb
|
||||
+++ b/spec/websocket/extensions_spec.rb
|
||||
@@ -134,18 +134,18 @@
|
||||
end
|
||||
|
||||
it "activates one session with a boolean param" do
|
||||
- expect(@session).to receive(:activate).with("gzip" => true).exactly(1).and_return(true)
|
||||
+ expect(@session).to receive(:activate).with({ "gzip" => true }).exactly(1).and_return(true)
|
||||
@extensions.activate("deflate; gzip")
|
||||
end
|
||||
|
||||
it "activates one session with a string param" do
|
||||
- expect(@session).to receive(:activate).with("mode" => "compress").exactly(1).and_return(true)
|
||||
+ expect(@session).to receive(:activate).with({ "mode" => "compress" }).exactly(1).and_return(true)
|
||||
@extensions.activate("deflate; mode=compress")
|
||||
end
|
||||
|
||||
it "activate multiple sessions" do
|
||||
- expect(@session).to receive(:activate).with("a" => true).exactly(1).and_return(true)
|
||||
- expect(@nonconflict_session).to receive(:activate).with("b" => true).exactly(1).and_return(true)
|
||||
+ expect(@session).to receive(:activate).with({ "a" => true }).exactly(1).and_return(true)
|
||||
+ expect(@nonconflict_session).to receive(:activate).with({ "b" => true }).exactly(1).and_return(true)
|
||||
@extensions.activate("deflate; a, reverse; b")
|
||||
end
|
||||
|
||||
73
rubygem-websocket-extensions.spec
Normal file
73
rubygem-websocket-extensions.spec
Normal file
@ -0,0 +1,73 @@
|
||||
%global gem_name websocket-extensions
|
||||
Name: rubygem-%{gem_name}
|
||||
Version: 0.1.5
|
||||
Release: 1
|
||||
Summary: Generic extension manager for WebSocket connections
|
||||
License: MIT
|
||||
URL: http://github.com/faye/websocket-extensions-ruby
|
||||
Source0: https://rubygems.org/gems/websocket-extensions-%{version}.gem
|
||||
Source1: https://github.com/faye/websocket-extensions-ruby/archive/%{version}.tar.gz
|
||||
Patch1: As-of-rspec-mocks-v3.10.3-mock-expectations-need-to-use.patch
|
||||
BuildRequires: ruby(release) rubygems-devel ruby rubygem(rspec)
|
||||
BuildRequires: rubygem(did_you_mean)
|
||||
BuildArch: noarch
|
||||
%description
|
||||
Generic extension manager for WebSocket connections.
|
||||
|
||||
%package doc
|
||||
Summary: Documentation for %{name}
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
BuildArch: noarch
|
||||
%description doc
|
||||
Documentation for %{name}.
|
||||
|
||||
%prep
|
||||
gem unpack %{SOURCE0}
|
||||
%setup -q -D -T -n %{gem_name}-%{version}
|
||||
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
|
||||
|
||||
%build
|
||||
gem build %{gem_name}.gemspec
|
||||
%gem_install
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{gem_dir}
|
||||
cp -a .%{gem_dir}/* \
|
||||
%{buildroot}%{gem_dir}/
|
||||
|
||||
%check
|
||||
pushd .%{gem_instdir}
|
||||
tar -xzf %{SOURCE1}
|
||||
cd %{gem_name}-ruby-%{version}
|
||||
cat %{PATCH1} | patch -p1
|
||||
rspec spec
|
||||
popd
|
||||
|
||||
%files
|
||||
%dir %{gem_instdir}
|
||||
%exclude %{gem_instdir}/.*
|
||||
%{gem_libdir}
|
||||
%exclude %{gem_cache}
|
||||
%{gem_spec}
|
||||
|
||||
%files doc
|
||||
%doc %{gem_docdir}
|
||||
%doc %{gem_instdir}/CHANGELOG.md
|
||||
%doc %{gem_instdir}/README.md
|
||||
%license %{gem_instdir}/LICENSE.md
|
||||
|
||||
%changelog
|
||||
* Wed Nov 15 2023 Ge Wang <wang__ge@126.com> - 0.1.5-1
|
||||
- Update to version 0.1.5
|
||||
|
||||
* Tue Aug 1 2023 liyanan <thistleslyn@163.com> - 0.1.2-4
|
||||
- Fix build error for Ruby 3.2
|
||||
|
||||
* Tue Jan 17 2023 yaoxin <yaoxin30@h-partners.com> - 0.1.2-3
|
||||
- Fix build failed due to ruby update to 3.1.3
|
||||
|
||||
* Thu Feb 24 2022 wangkai <wangkai385@huawei.com> - 0.1.2-2
|
||||
- Fix CVE-2020-7663
|
||||
|
||||
* Sat Aug 8 2020 yanan li <liyanan032@huawei.com> - 0.1.2-1
|
||||
- Package init
|
||||
5
rubygem-websocket-extensions.yaml
Normal file
5
rubygem-websocket-extensions.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
git_url: https://github.com/faye/websocket-extensions-ruby.git
|
||||
version_control: github
|
||||
src_repo: faye/websocket-extensions-ruby
|
||||
tag_prefix: ""
|
||||
seperator: "."
|
||||
BIN
websocket-extensions-0.1.5.gem
Normal file
BIN
websocket-extensions-0.1.5.gem
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user