pubnub 4.0.15 → 4.0.16

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of pubnub might be problematic. Click here for more details.

Files changed (46) hide show
  1. checksums.yaml +4 -4
  2. data/.pubnub.yml +7 -0
  3. data/CHANGELOG.md +3 -0
  4. data/Gemfile.lock +5 -7
  5. data/VERSION +1 -1
  6. data/fixtures/vcr_cassettes/examples/leave/0.yml +5 -5
  7. data/fixtures/vcr_cassettes/examples/leave/1.yml +5 -5
  8. data/fixtures/vcr_cassettes/examples/leave/10.yml +6 -6
  9. data/fixtures/vcr_cassettes/examples/leave/11.yml +6 -6
  10. data/fixtures/vcr_cassettes/examples/leave/12.yml +5 -5
  11. data/fixtures/vcr_cassettes/examples/leave/13.yml +6 -6
  12. data/fixtures/vcr_cassettes/examples/leave/14.yml +6 -6
  13. data/fixtures/vcr_cassettes/examples/leave/15.yml +5 -5
  14. data/fixtures/vcr_cassettes/examples/leave/16.yml +5 -5
  15. data/fixtures/vcr_cassettes/examples/leave/17.yml +5 -5
  16. data/fixtures/vcr_cassettes/examples/leave/18.yml +6 -6
  17. data/fixtures/vcr_cassettes/examples/leave/19.yml +5 -5
  18. data/fixtures/vcr_cassettes/examples/leave/2.yml +5 -5
  19. data/fixtures/vcr_cassettes/examples/leave/20.yml +5 -5
  20. data/fixtures/vcr_cassettes/examples/leave/21.yml +6 -6
  21. data/fixtures/vcr_cassettes/examples/leave/22.yml +5 -5
  22. data/fixtures/vcr_cassettes/examples/leave/23.yml +5 -5
  23. data/fixtures/vcr_cassettes/examples/leave/24.yml +5 -5
  24. data/fixtures/vcr_cassettes/examples/leave/25.yml +5 -5
  25. data/fixtures/vcr_cassettes/examples/leave/26.yml +5 -5
  26. data/fixtures/vcr_cassettes/examples/leave/27.yml +6 -6
  27. data/fixtures/vcr_cassettes/examples/leave/28.yml +6 -6
  28. data/fixtures/vcr_cassettes/examples/leave/29.yml +6 -6
  29. data/fixtures/vcr_cassettes/examples/leave/3.yml +5 -5
  30. data/fixtures/vcr_cassettes/examples/leave/30.yml +5 -5
  31. data/fixtures/vcr_cassettes/examples/leave/31.yml +5 -5
  32. data/fixtures/vcr_cassettes/examples/leave/32.yml +6 -6
  33. data/fixtures/vcr_cassettes/examples/leave/33.yml +5 -5
  34. data/fixtures/vcr_cassettes/examples/leave/34.yml +6 -6
  35. data/fixtures/vcr_cassettes/examples/leave/35.yml +5 -5
  36. data/fixtures/vcr_cassettes/examples/leave/4.yml +5 -5
  37. data/fixtures/vcr_cassettes/examples/leave/5.yml +5 -5
  38. data/fixtures/vcr_cassettes/examples/leave/6.yml +5 -5
  39. data/fixtures/vcr_cassettes/examples/leave/7.yml +5 -5
  40. data/fixtures/vcr_cassettes/examples/leave/8.yml +6 -6
  41. data/fixtures/vcr_cassettes/examples/leave/9.yml +6 -6
  42. data/lib/pubnub/events/leave.rb +6 -0
  43. data/lib/pubnub/events/publish.rb +2 -2
  44. data/lib/pubnub/version.rb +1 -1
  45. data/spec/examples/leave_examples_spec.rb +36 -36
  46. metadata +2 -2
@@ -2,24 +2,24 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: http://pubsub.pubnub.com/v2/presence/sub-key/sub-c-b7fb805a-1777-11e6-be83-0619f8945a4f/channel/demo/leave?auth=ruby-test-auth-client-one&pnsdk=PubNub-Ruby/4.0.0&uuid=ruby-test-uuid-client-one
5
+ uri: http://pubsub.pubnub.com/v2/presence/sub-key/sub-c-b7fb805a-1777-11e6-be83-0619f8945a4f/channel/demo/leave?auth=ruby-test-auth-client-one&pnsdk=PubNub-Ruby/4.0.15&uuid=ruby-test-uuid-client-one
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: ''
9
9
  headers:
10
10
  User-Agent:
11
- - HTTPClient/1.0 (2.8.0, ruby 2.3.0 (2015-12-25))
11
+ - HTTPClient/1.0 (2.8.2.4, ruby 2.3.2 (2016-11-15))
12
12
  Accept:
13
13
  - "*/*"
14
14
  Date:
15
- - Wed, 25 May 2016 15:15:29 GMT
15
+ - Tue, 22 Nov 2016 21:44:29 GMT
16
16
  response:
17
17
  status:
18
18
  code: 200
19
19
  message: OK
20
20
  headers:
21
21
  Date:
22
- - Wed, 25 May 2016 15:15:29 GMT
22
+ - Tue, 22 Nov 2016 21:44:30 GMT
23
23
  Content-Type:
24
24
  - text/javascript; charset="UTF-8"
25
25
  Content-Length:
@@ -42,5 +42,5 @@ http_interactions:
42
42
  encoding: UTF-8
43
43
  string: '{"status": 200, "action": "leave", "message": "OK", "service": "Presence"}'
44
44
  http_version:
45
- recorded_at: Wed, 25 May 2016 15:15:29 GMT
45
+ recorded_at: Tue, 22 Nov 2016 21:44:30 GMT
46
46
  recorded_with: VCR 3.0.1
@@ -2,24 +2,24 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: http://pubsub.pubnub.com/v2/presence/sub-key/sub-c-b7fb805a-1777-11e6-be83-0619f8945a4f/channel/demo/leave?auth=ruby-test-auth-client-one&pnsdk=PubNub-Ruby/4.0.0&uuid=ruby-test-uuid-client-one
5
+ uri: http://pubsub.pubnub.com/v2/presence/sub-key/sub-c-b7fb805a-1777-11e6-be83-0619f8945a4f/channel/demo/leave?auth=ruby-test-auth-client-one&pnsdk=PubNub-Ruby/4.0.15&uuid=ruby-test-uuid-client-one
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: ''
9
9
  headers:
10
10
  User-Agent:
11
- - HTTPClient/1.0 (2.8.0, ruby 2.3.0 (2015-12-25))
11
+ - HTTPClient/1.0 (2.8.2.4, ruby 2.3.2 (2016-11-15))
12
12
  Accept:
13
13
  - "*/*"
14
14
  Date:
15
- - Wed, 25 May 2016 15:15:28 GMT
15
+ - Tue, 22 Nov 2016 21:44:29 GMT
16
16
  response:
17
17
  status:
18
18
  code: 200
19
19
  message: OK
20
20
  headers:
21
21
  Date:
22
- - Wed, 25 May 2016 15:15:28 GMT
22
+ - Tue, 22 Nov 2016 21:44:29 GMT
23
23
  Content-Type:
24
24
  - text/javascript; charset="UTF-8"
25
25
  Content-Length:
@@ -35,12 +35,12 @@ http_interactions:
35
35
  Accept-Ranges:
36
36
  - bytes
37
37
  Age:
38
- - '0'
38
+ - '1'
39
39
  Server:
40
40
  - Pubnub Presence
41
41
  body:
42
42
  encoding: UTF-8
43
43
  string: '{"status": 200, "action": "leave", "message": "OK", "service": "Presence"}'
44
44
  http_version:
45
- recorded_at: Wed, 25 May 2016 15:15:28 GMT
45
+ recorded_at: Tue, 22 Nov 2016 21:44:29 GMT
46
46
  recorded_with: VCR 3.0.1
@@ -2,24 +2,24 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: http://pubsub.pubnub.com/v2/presence/sub-key/sub-c-b7fb805a-1777-11e6-be83-0619f8945a4f/channel/demo/leave?auth=ruby-test-auth-client-one&pnsdk=PubNub-Ruby/4.0.0&uuid=ruby-test-uuid-client-one
5
+ uri: http://pubsub.pubnub.com/v2/presence/sub-key/sub-c-b7fb805a-1777-11e6-be83-0619f8945a4f/channel/demo/leave?auth=ruby-test-auth-client-one&pnsdk=PubNub-Ruby/4.0.15&uuid=ruby-test-uuid-client-one
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: ''
9
9
  headers:
10
10
  User-Agent:
11
- - HTTPClient/1.0 (2.8.0, ruby 2.3.0 (2015-12-25))
11
+ - HTTPClient/1.0 (2.8.2.4, ruby 2.3.2 (2016-11-15))
12
12
  Accept:
13
13
  - "*/*"
14
14
  Date:
15
- - Wed, 25 May 2016 15:15:27 GMT
15
+ - Tue, 22 Nov 2016 21:44:29 GMT
16
16
  response:
17
17
  status:
18
18
  code: 200
19
19
  message: OK
20
20
  headers:
21
21
  Date:
22
- - Wed, 25 May 2016 15:15:27 GMT
22
+ - Tue, 22 Nov 2016 21:44:29 GMT
23
23
  Content-Type:
24
24
  - text/javascript; charset="UTF-8"
25
25
  Content-Length:
@@ -35,12 +35,12 @@ http_interactions:
35
35
  Accept-Ranges:
36
36
  - bytes
37
37
  Age:
38
- - '0'
38
+ - '1'
39
39
  Server:
40
40
  - Pubnub Presence
41
41
  body:
42
42
  encoding: UTF-8
43
43
  string: '{"status": 200, "action": "leave", "message": "OK", "service": "Presence"}'
44
44
  http_version:
45
- recorded_at: Wed, 25 May 2016 15:15:27 GMT
45
+ recorded_at: Tue, 22 Nov 2016 21:44:29 GMT
46
46
  recorded_with: VCR 3.0.1
@@ -34,6 +34,12 @@ module Pubnub
34
34
  ].join('/')
35
35
  end
36
36
 
37
+ def parameters(*_args)
38
+ params = super
39
+ params.merge!('channel-group' => @group.join(',')) unless @group.empty?
40
+ params
41
+ end
42
+
37
43
  def valid_envelope(parsed_response, req_res_objects)
38
44
  Pubnub::Envelope.new(
39
45
  event: @event,
@@ -97,11 +97,11 @@ module Pubnub
97
97
  nil
98
98
  end
99
99
 
100
- def valid_envelope(_parsed_response, req_res_objects)
100
+ def valid_envelope(parsed_response, req_res_objects)
101
101
  Pubnub::Envelope.new(
102
102
  event: @event,
103
103
  event_options: @given_options,
104
- timetoken: nil,
104
+ timetoken: timetoken(parsed_response),
105
105
  status: {
106
106
  code: req_res_objects[:response].code,
107
107
  operation: Pubnub::Constants::OPERATION_PUBLISH,
@@ -1,4 +1,4 @@
1
1
  # Toplevel Pubnub module.
2
2
  module Pubnub
3
- VERSION = '4.0.15'
3
+ VERSION = '4.0.16'
4
4
  end
@@ -21,7 +21,7 @@ describe Pubnub::Leave do
21
21
  end
22
22
 
23
23
  it '__channel___demo___channel_group__nil___http_sync__true___callback__nil_' do
24
- VCR.use_cassette('examples/leave/17', record: :none) do
24
+ VCR.use_cassette('examples/leave/17', record: :once) do
25
25
  envelope = @pubnub.leave(channel: :demo, http_sync: true)
26
26
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
27
27
  expect(envelope.error?).to eq false
@@ -37,7 +37,7 @@ end
37
37
 
38
38
 
39
39
  it '__channel___demo___channel_group__nil___http_sync__true___callback___block_' do
40
- VCR.use_cassette('examples/leave/15', record: :none) do
40
+ VCR.use_cassette('examples/leave/15', record: :once) do
41
41
  envelope = @pubnub.leave(channel: :demo, http_sync: true, &@callback)
42
42
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
43
43
  expect(envelope.error?).to eq false
@@ -53,7 +53,7 @@ end
53
53
 
54
54
 
55
55
  it '__channel___demo___channel_group__nil___http_sync__true___callback___lambda_' do
56
- VCR.use_cassette('examples/leave/16', record: :none) do
56
+ VCR.use_cassette('examples/leave/16', record: :once) do
57
57
  envelope = @pubnub.leave(channel: :demo, http_sync: true, callback: @callback)
58
58
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
59
59
  expect(envelope.error?).to eq false
@@ -69,7 +69,7 @@ end
69
69
 
70
70
 
71
71
  it '__channel___demo___channel_group__nil___http_sync__false___callback__nil_' do
72
- VCR.use_cassette('examples/leave/14', record: :none) do
72
+ VCR.use_cassette('examples/leave/14', record: :once) do
73
73
  envelope = @pubnub.leave(channel: :demo, http_sync: false)
74
74
  envelope = envelope.value
75
75
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -86,7 +86,7 @@ end
86
86
 
87
87
 
88
88
  it '__channel___demo___channel_group__nil___http_sync__false___callback___block_' do
89
- VCR.use_cassette('examples/leave/12', record: :none) do
89
+ VCR.use_cassette('examples/leave/12', record: :once) do
90
90
  envelope = @pubnub.leave(channel: :demo, http_sync: false, &@callback)
91
91
  envelope = envelope.value
92
92
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -103,7 +103,7 @@ end
103
103
 
104
104
 
105
105
  it '__channel___demo___channel_group__nil___http_sync__false___callback___lambda_' do
106
- VCR.use_cassette('examples/leave/13', record: :none) do
106
+ VCR.use_cassette('examples/leave/13', record: :once) do
107
107
  envelope = @pubnub.leave(channel: :demo, http_sync: false, callback: @callback)
108
108
  envelope = envelope.value
109
109
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -120,7 +120,7 @@ end
120
120
 
121
121
 
122
122
  it '__channel___demo____channel_group__nil___http_sync__true___callback__nil_' do
123
- VCR.use_cassette('examples/leave/11', record: :none) do
123
+ VCR.use_cassette('examples/leave/11', record: :once) do
124
124
  envelope = @pubnub.leave(channel: 'demo', http_sync: true)
125
125
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
126
126
  expect(envelope.error?).to eq false
@@ -136,7 +136,7 @@ end
136
136
 
137
137
 
138
138
  it '__channel___demo____channel_group__nil___http_sync__true___callback___block_' do
139
- VCR.use_cassette('examples/leave/9', record: :none) do
139
+ VCR.use_cassette('examples/leave/9', record: :once) do
140
140
  envelope = @pubnub.leave(channel: 'demo', http_sync: true, &@callback)
141
141
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
142
142
  expect(envelope.error?).to eq false
@@ -152,7 +152,7 @@ end
152
152
 
153
153
 
154
154
  it '__channel___demo____channel_group__nil___http_sync__true___callback___lambda_' do
155
- VCR.use_cassette('examples/leave/10', record: :none) do
155
+ VCR.use_cassette('examples/leave/10', record: :once) do
156
156
  envelope = @pubnub.leave(channel: 'demo', http_sync: true, callback: @callback)
157
157
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
158
158
  expect(envelope.error?).to eq false
@@ -168,7 +168,7 @@ end
168
168
 
169
169
 
170
170
  it '__channel___demo____channel_group__nil___http_sync__false___callback__nil_' do
171
- VCR.use_cassette('examples/leave/8', record: :none) do
171
+ VCR.use_cassette('examples/leave/8', record: :once) do
172
172
  envelope = @pubnub.leave(channel: 'demo', http_sync: false)
173
173
  envelope = envelope.value
174
174
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -185,7 +185,7 @@ end
185
185
 
186
186
 
187
187
  it '__channel___demo____channel_group__nil___http_sync__false___callback___block_' do
188
- VCR.use_cassette('examples/leave/6', record: :none) do
188
+ VCR.use_cassette('examples/leave/6', record: :once) do
189
189
  envelope = @pubnub.leave(channel: 'demo', http_sync: false, &@callback)
190
190
  envelope = envelope.value
191
191
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -202,7 +202,7 @@ end
202
202
 
203
203
 
204
204
  it '__channel___demo____channel_group__nil___http_sync__false___callback___lambda_' do
205
- VCR.use_cassette('examples/leave/7', record: :none) do
205
+ VCR.use_cassette('examples/leave/7', record: :once) do
206
206
  envelope = @pubnub.leave(channel: 'demo', http_sync: false, callback: @callback)
207
207
  envelope = envelope.value
208
208
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -219,7 +219,7 @@ end
219
219
 
220
220
 
221
221
  it '__channel____demo___demo_____channel_group__nil___http_sync__true___callback__nil_' do
222
- VCR.use_cassette('examples/leave/5', record: :none) do
222
+ VCR.use_cassette('examples/leave/5', record: :once) do
223
223
  envelope = @pubnub.leave(channel: [:demo, "demo"], http_sync: true)
224
224
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
225
225
  expect(envelope.error?).to eq false
@@ -235,7 +235,7 @@ end
235
235
 
236
236
 
237
237
  it '__channel____demo___demo_____channel_group__nil___http_sync__true___callback___block_' do
238
- VCR.use_cassette('examples/leave/3', record: :none) do
238
+ VCR.use_cassette('examples/leave/3', record: :once) do
239
239
  envelope = @pubnub.leave(channel: [:demo, "demo"], http_sync: true, &@callback)
240
240
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
241
241
  expect(envelope.error?).to eq false
@@ -251,7 +251,7 @@ end
251
251
 
252
252
 
253
253
  it '__channel____demo___demo_____channel_group__nil___http_sync__true___callback___lambda_' do
254
- VCR.use_cassette('examples/leave/4', record: :none) do
254
+ VCR.use_cassette('examples/leave/4', record: :once) do
255
255
  envelope = @pubnub.leave(channel: [:demo, "demo"], http_sync: true, callback: @callback)
256
256
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
257
257
  expect(envelope.error?).to eq false
@@ -267,7 +267,7 @@ end
267
267
 
268
268
 
269
269
  it '__channel____demo___demo_____channel_group__nil___http_sync__false___callback__nil_' do
270
- VCR.use_cassette('examples/leave/2', record: :none) do
270
+ VCR.use_cassette('examples/leave/2', record: :once) do
271
271
  envelope = @pubnub.leave(channel: [:demo, "demo"], http_sync: false)
272
272
  envelope = envelope.value
273
273
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -284,7 +284,7 @@ end
284
284
 
285
285
 
286
286
  it '__channel____demo___demo_____channel_group__nil___http_sync__false___callback___block_' do
287
- VCR.use_cassette('examples/leave/0', record: :none) do
287
+ VCR.use_cassette('examples/leave/0', record: :once) do
288
288
  envelope = @pubnub.leave(channel: [:demo, "demo"], http_sync: false, &@callback)
289
289
  envelope = envelope.value
290
290
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -301,7 +301,7 @@ end
301
301
 
302
302
 
303
303
  it '__channel____demo___demo_____channel_group__nil___http_sync__false___callback___lambda_' do
304
- VCR.use_cassette('examples/leave/1', record: :none) do
304
+ VCR.use_cassette('examples/leave/1', record: :once) do
305
305
  envelope = @pubnub.leave(channel: [:demo, "demo"], http_sync: false, callback: @callback)
306
306
  envelope = envelope.value
307
307
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -318,7 +318,7 @@ end
318
318
 
319
319
 
320
320
  it '__channel__nil___channel_group___demo___http_sync__true___callback__nil_' do
321
- VCR.use_cassette('examples/leave/35', record: :none) do
321
+ VCR.use_cassette('examples/leave/35', record: :once) do
322
322
  envelope = @pubnub.leave(channel_group: :demo, http_sync: true)
323
323
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
324
324
  expect(envelope.error?).to eq false
@@ -334,7 +334,7 @@ end
334
334
 
335
335
 
336
336
  it '__channel__nil___channel_group___demo___http_sync__true___callback___block_' do
337
- VCR.use_cassette('examples/leave/33', record: :none) do
337
+ VCR.use_cassette('examples/leave/33', record: :once) do
338
338
  envelope = @pubnub.leave(channel_group: :demo, http_sync: true, &@callback)
339
339
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
340
340
  expect(envelope.error?).to eq false
@@ -350,7 +350,7 @@ end
350
350
 
351
351
 
352
352
  it '__channel__nil___channel_group___demo___http_sync__true___callback___lambda_' do
353
- VCR.use_cassette('examples/leave/34', record: :none) do
353
+ VCR.use_cassette('examples/leave/34', record: :once) do
354
354
  envelope = @pubnub.leave(channel_group: :demo, http_sync: true, callback: @callback)
355
355
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
356
356
  expect(envelope.error?).to eq false
@@ -366,7 +366,7 @@ end
366
366
 
367
367
 
368
368
  it '__channel__nil___channel_group___demo___http_sync__false___callback__nil_' do
369
- VCR.use_cassette('examples/leave/32', record: :none) do
369
+ VCR.use_cassette('examples/leave/32', record: :once) do
370
370
  envelope = @pubnub.leave(channel_group: :demo, http_sync: false)
371
371
  envelope = envelope.value
372
372
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -383,7 +383,7 @@ end
383
383
 
384
384
 
385
385
  it '__channel__nil___channel_group___demo___http_sync__false___callback___block_' do
386
- VCR.use_cassette('examples/leave/30', record: :none) do
386
+ VCR.use_cassette('examples/leave/30', record: :once) do
387
387
  envelope = @pubnub.leave(channel_group: :demo, http_sync: false, &@callback)
388
388
  envelope = envelope.value
389
389
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -400,7 +400,7 @@ end
400
400
 
401
401
 
402
402
  it '__channel__nil___channel_group___demo___http_sync__false___callback___lambda_' do
403
- VCR.use_cassette('examples/leave/31', record: :none) do
403
+ VCR.use_cassette('examples/leave/31', record: :once) do
404
404
  envelope = @pubnub.leave(channel_group: :demo, http_sync: false, callback: @callback)
405
405
  envelope = envelope.value
406
406
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -417,7 +417,7 @@ end
417
417
 
418
418
 
419
419
  it '__channel__nil___channel_group___demo____http_sync__true___callback__nil_' do
420
- VCR.use_cassette('examples/leave/29', record: :none) do
420
+ VCR.use_cassette('examples/leave/29', record: :once) do
421
421
  envelope = @pubnub.leave(channel_group: 'demo', http_sync: true)
422
422
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
423
423
  expect(envelope.error?).to eq false
@@ -433,7 +433,7 @@ end
433
433
 
434
434
 
435
435
  it '__channel__nil___channel_group___demo____http_sync__true___callback___block_' do
436
- VCR.use_cassette('examples/leave/27', record: :none) do
436
+ VCR.use_cassette('examples/leave/27', record: :once) do
437
437
  envelope = @pubnub.leave(channel_group: 'demo', http_sync: true, &@callback)
438
438
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
439
439
  expect(envelope.error?).to eq false
@@ -449,7 +449,7 @@ end
449
449
 
450
450
 
451
451
  it '__channel__nil___channel_group___demo____http_sync__true___callback___lambda_' do
452
- VCR.use_cassette('examples/leave/28', record: :none) do
452
+ VCR.use_cassette('examples/leave/28', record: :once) do
453
453
  envelope = @pubnub.leave(channel_group: 'demo', http_sync: true, callback: @callback)
454
454
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
455
455
  expect(envelope.error?).to eq false
@@ -465,7 +465,7 @@ end
465
465
 
466
466
 
467
467
  it '__channel__nil___channel_group___demo____http_sync__false___callback__nil_' do
468
- VCR.use_cassette('examples/leave/26', record: :none) do
468
+ VCR.use_cassette('examples/leave/26', record: :once) do
469
469
  envelope = @pubnub.leave(channel_group: 'demo', http_sync: false)
470
470
  envelope = envelope.value
471
471
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -482,7 +482,7 @@ end
482
482
 
483
483
 
484
484
  it '__channel__nil___channel_group___demo____http_sync__false___callback___block_' do
485
- VCR.use_cassette('examples/leave/24', record: :none) do
485
+ VCR.use_cassette('examples/leave/24', record: :once) do
486
486
  envelope = @pubnub.leave(channel_group: 'demo', http_sync: false, &@callback)
487
487
  envelope = envelope.value
488
488
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -499,7 +499,7 @@ end
499
499
 
500
500
 
501
501
  it '__channel__nil___channel_group___demo____http_sync__false___callback___lambda_' do
502
- VCR.use_cassette('examples/leave/25', record: :none) do
502
+ VCR.use_cassette('examples/leave/25', record: :once) do
503
503
  envelope = @pubnub.leave(channel_group: 'demo', http_sync: false, callback: @callback)
504
504
  envelope = envelope.value
505
505
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -516,7 +516,7 @@ end
516
516
 
517
517
 
518
518
  it '__channel__nil___channel_group____demo___demo_____http_sync__true___callback__nil_' do
519
- VCR.use_cassette('examples/leave/23', record: :none) do
519
+ VCR.use_cassette('examples/leave/23', record: :once) do
520
520
  envelope = @pubnub.leave(channel_group: [:demo, "demo"], http_sync: true)
521
521
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
522
522
  expect(envelope.error?).to eq false
@@ -532,7 +532,7 @@ end
532
532
 
533
533
 
534
534
  it '__channel__nil___channel_group____demo___demo_____http_sync__true___callback___block_' do
535
- VCR.use_cassette('examples/leave/21', record: :none) do
535
+ VCR.use_cassette('examples/leave/21', record: :once) do
536
536
  envelope = @pubnub.leave(channel_group: [:demo, "demo"], http_sync: true, &@callback)
537
537
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
538
538
  expect(envelope.error?).to eq false
@@ -548,7 +548,7 @@ end
548
548
 
549
549
 
550
550
  it '__channel__nil___channel_group____demo___demo_____http_sync__true___callback___lambda_' do
551
- VCR.use_cassette('examples/leave/22', record: :none) do
551
+ VCR.use_cassette('examples/leave/22', record: :once) do
552
552
  envelope = @pubnub.leave(channel_group: [:demo, "demo"], http_sync: true, callback: @callback)
553
553
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
554
554
  expect(envelope.error?).to eq false
@@ -564,7 +564,7 @@ end
564
564
 
565
565
 
566
566
  it '__channel__nil___channel_group____demo___demo_____http_sync__false___callback__nil_' do
567
- VCR.use_cassette('examples/leave/20', record: :none) do
567
+ VCR.use_cassette('examples/leave/20', record: :once) do
568
568
  envelope = @pubnub.leave(channel_group: [:demo, "demo"], http_sync: false)
569
569
  envelope = envelope.value
570
570
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -581,7 +581,7 @@ end
581
581
 
582
582
 
583
583
  it '__channel__nil___channel_group____demo___demo_____http_sync__false___callback___block_' do
584
- VCR.use_cassette('examples/leave/18', record: :none) do
584
+ VCR.use_cassette('examples/leave/18', record: :once) do
585
585
  envelope = @pubnub.leave(channel_group: [:demo, "demo"], http_sync: false, &@callback)
586
586
  envelope = envelope.value
587
587
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true
@@ -598,7 +598,7 @@ end
598
598
 
599
599
 
600
600
  it '__channel__nil___channel_group____demo___demo_____http_sync__false___callback___lambda_' do
601
- VCR.use_cassette('examples/leave/19', record: :none) do
601
+ VCR.use_cassette('examples/leave/19', record: :once) do
602
602
  envelope = @pubnub.leave(channel_group: [:demo, "demo"], http_sync: false, callback: @callback)
603
603
  envelope = envelope.value
604
604
  expect(envelope.is_a?(Pubnub::Envelope)).to eq true