ld-eventsource 2.0.1 → 2.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.circleci/config.yml +1 -1
- data/lib/ld-eventsource/client.rb +9 -0
- data/lib/ld-eventsource/version.rb +1 -1
- data/spec/client_spec.rb +15 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e62fdcf615bb0c699746e63a929e5eb582b8680cf873659d2be9e7e018fb0a89
|
4
|
+
data.tar.gz: f5f2b5694a3049e4f5dc2fd5f49de948ab6a8d040151d506a5589b0da4bca0f6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dd8ec3f6a4719860f1bf32bef767917a6b97753b8c9eb060c5478fa93b9115c3090313d5cfe4d00137dd1f764cb4bdfb3af000246718dd446691912f4c17ee1d
|
7
|
+
data.tar.gz: 23a6178d006572791caddbfb372bd9a4c68c5e9f32c272c7b3230008698744e973fcecee8d51b2bfc5471ba99f18190b95e0f074307b77dee81d1274b0416d07
|
data/.circleci/config.yml
CHANGED
@@ -190,6 +190,15 @@ module SSE
|
|
190
190
|
end
|
191
191
|
end
|
192
192
|
|
193
|
+
#
|
194
|
+
# Tests whether the client has been shut down by a call to {Client#close}.
|
195
|
+
#
|
196
|
+
# @return [Boolean] true if the client has been shut down
|
197
|
+
#
|
198
|
+
def closed?
|
199
|
+
@stopped.value
|
200
|
+
end
|
201
|
+
|
193
202
|
private
|
194
203
|
|
195
204
|
def reset_http
|
data/spec/client_spec.rb
CHANGED
@@ -426,4 +426,19 @@ EOT
|
|
426
426
|
end
|
427
427
|
end
|
428
428
|
end
|
429
|
+
|
430
|
+
it "returns true from closed? when closed" do
|
431
|
+
with_server do |server|
|
432
|
+
server.setup_response("/") do |req,res|
|
433
|
+
send_stream_content(res, "", keep_open: true)
|
434
|
+
end
|
435
|
+
|
436
|
+
with_client(subject.new(server.base_uri)) do |client|
|
437
|
+
expect(client.closed?).to be(false)
|
438
|
+
|
439
|
+
client.close
|
440
|
+
expect(client.closed?).to be(true)
|
441
|
+
end
|
442
|
+
end
|
443
|
+
end
|
429
444
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ld-eventsource
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0
|
4
|
+
version: 2.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- LaunchDarkly
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-08-
|
11
|
+
date: 2021-08-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|