pubnub 4.0.27 → 4.0.28

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 (119) hide show
  1. checksums.yaml +4 -4
  2. data/.pubnub.yml +8 -1
  3. data/.rubocop.yml +9 -3
  4. data/.travis.yml +6 -19
  5. data/CHANGELOG.md +86 -82
  6. data/Gemfile +7 -5
  7. data/Gemfile.lock +155 -157
  8. data/README.md +34 -34
  9. data/VERSION +1 -1
  10. data/gemfiles/celluloid_017.gemfile +4 -4
  11. data/gemfiles/celluloid_018.gemfile +4 -4
  12. data/gemfiles/celluloid_master.gemfile +4 -4
  13. data/gemfiles/concurrent-ruby-1.0.5.gem +0 -0
  14. data/gemfiles/concurrent-ruby-edge-0.3.1.gem +0 -0
  15. data/lib/pubnub.rb +3 -3
  16. data/lib/pubnub/client.rb +19 -16
  17. data/lib/pubnub/client/events.rb +5 -5
  18. data/lib/pubnub/client/getters_setters.rb +11 -12
  19. data/lib/pubnub/client/paged_history.rb +11 -9
  20. data/lib/pubnub/configuration.rb +1 -2
  21. data/lib/pubnub/constants.rb +47 -47
  22. data/lib/pubnub/crypto.rb +2 -2
  23. data/lib/pubnub/envelope.rb +7 -5
  24. data/lib/pubnub/error.rb +22 -15
  25. data/lib/pubnub/event.rb +24 -25
  26. data/lib/pubnub/event/formatter.rb +8 -5
  27. data/lib/pubnub/event/signature.rb +3 -3
  28. data/lib/pubnub/events/audit.rb +1 -1
  29. data/lib/pubnub/events/channel_registration.rb +10 -15
  30. data/lib/pubnub/events/delete_messages.rb +9 -9
  31. data/lib/pubnub/events/grant.rb +3 -3
  32. data/lib/pubnub/events/heartbeat.rb +4 -8
  33. data/lib/pubnub/events/here_now.rb +4 -8
  34. data/lib/pubnub/events/history.rb +10 -10
  35. data/lib/pubnub/events/leave.rb +2 -2
  36. data/lib/pubnub/events/presence.rb +1 -1
  37. data/lib/pubnub/events/publish.rb +3 -5
  38. data/lib/pubnub/events/revoke.rb +3 -3
  39. data/lib/pubnub/events/set_state.rb +3 -3
  40. data/lib/pubnub/events/state.rb +4 -6
  41. data/lib/pubnub/events/subscribe.rb +1 -1
  42. data/lib/pubnub/events/time.rb +2 -2
  43. data/lib/pubnub/events/where_now.rb +6 -6
  44. data/lib/pubnub/format.rb +73 -0
  45. data/lib/pubnub/formatter.rb +23 -21
  46. data/lib/pubnub/heart.rb +4 -4
  47. data/lib/pubnub/origin_manager.rb +3 -5
  48. data/lib/pubnub/pam.rb +5 -5
  49. data/lib/pubnub/schemas/envelope_schema.rb +1 -1
  50. data/lib/pubnub/subscribe_callback.rb +3 -3
  51. data/lib/pubnub/subscribe_event.rb +6 -10
  52. data/lib/pubnub/subscribe_event/formatter.rb +82 -80
  53. data/lib/pubnub/subscribe_event/heartbeat.rb +1 -1
  54. data/lib/pubnub/subscriber.rb +31 -32
  55. data/lib/pubnub/telemetry.rb +26 -27
  56. data/lib/pubnub/validators/audit.rb +3 -2
  57. data/lib/pubnub/validators/channel_registration.rb +6 -4
  58. data/lib/pubnub/validators/client.rb +1 -0
  59. data/lib/pubnub/validators/common_validator.rb +37 -31
  60. data/lib/pubnub/validators/delete.rb +5 -4
  61. data/lib/pubnub/validators/grant.rb +3 -2
  62. data/lib/pubnub/validators/history.rb +3 -2
  63. data/lib/pubnub/validators/leave.rb +3 -2
  64. data/lib/pubnub/validators/presence.rb +3 -2
  65. data/lib/pubnub/validators/publish.rb +15 -10
  66. data/lib/pubnub/validators/set_state.rb +0 -2
  67. data/lib/pubnub/validators/state.rb +3 -2
  68. data/lib/pubnub/version.rb +1 -1
  69. data/pubnub.gemspec +19 -18
  70. data/spec/examples/audit_examples_spec.rb +1268 -1418
  71. data/spec/examples/channel_registration_examples_spec.rb +655 -757
  72. data/spec/examples/delete_messages_examples_spec.rb +19 -21
  73. data/spec/examples/grant_examples_spec.rb +34028 -37920
  74. data/spec/examples/heartbeat_examples_spec.rb +583 -731
  75. data/spec/examples/here_now_examples_spec.rb +493 -569
  76. data/spec/examples/history_examples_spec.rb +979 -1127
  77. data/spec/examples/leave_examples_spec.rb +439 -551
  78. data/spec/examples/presence_examples_spec.rb +686 -830
  79. data/spec/examples/publish_examples_spec.rb +27223 -31547
  80. data/spec/examples/publish_with_ttl_spec.rb +11 -14
  81. data/spec/examples/revoke_examples_spec.rb +68048 -75828
  82. data/spec/examples/set_state_examples_spec.rb +295 -371
  83. data/spec/examples/state_examples_spec.rb +169 -197
  84. data/spec/examples/status_request_message_count_exceeded_spec.rb +16 -19
  85. data/spec/examples/subscribe_examples_spec.rb +43843 -52035
  86. data/spec/examples/time_examples_spec.rb +82 -98
  87. data/spec/examples/where_now_examples_spec.rb +88 -104
  88. data/spec/lib/client_spec.rb +99 -117
  89. data/spec/lib/connection_callback_spec.rb +27 -33
  90. data/spec/lib/custom_retries_examples_spec.rb +8 -11
  91. data/spec/lib/event_spec.rb +35 -42
  92. data/spec/lib/events/audit_spec.rb +19 -25
  93. data/spec/lib/events/channel_registration_spec.rb +17 -23
  94. data/spec/lib/events/delete_messages_spec.rb +14 -20
  95. data/spec/lib/events/grant_spec.rb +15 -21
  96. data/spec/lib/events/heartbeat_spec.rb +21 -27
  97. data/spec/lib/events/here_now_spec.rb +14 -20
  98. data/spec/lib/events/history_spec.rb +14 -20
  99. data/spec/lib/events/leave_spec.rb +14 -20
  100. data/spec/lib/events/presence_delta_spec.rb +15 -16
  101. data/spec/lib/events/presence_spec.rb +36 -45
  102. data/spec/lib/events/publish_spec.rb +33 -40
  103. data/spec/lib/events/revoke_spec.rb +16 -22
  104. data/spec/lib/events/state_spec.rb +16 -22
  105. data/spec/lib/events/subscribe_spec.rb +75 -85
  106. data/spec/lib/events/time_spec.rb +12 -18
  107. data/spec/lib/events/timeout_handling_spec.rb +8 -14
  108. data/spec/lib/events/where_now_spec.rb +14 -20
  109. data/spec/lib/keep_alive_spec.rb +4 -8
  110. data/spec/lib/multiple_ciphers_spec.rb +56 -60
  111. data/spec/lib/pubnub_spec.rb +10 -13
  112. data/spec/lib/signatures_spec.rb +118 -120
  113. data/spec/lib/ssl_error_spec.rb +14 -18
  114. data/spec/lib/super_admin_spec.rb +58 -66
  115. data/spec/lib/uuid_spec.rb +3 -4
  116. data/spec/spec_expectations.rb +3 -3
  117. data/spec/spec_helper.rb +29 -46
  118. metadata +52 -22
  119. data/lib/pubnub/message.rb +0 -43
@@ -1,37 +1,33 @@
1
- require 'spec_helper'
2
-
3
- describe 'Super admin mode' do
1
+ require "spec_helper"
4
2
 
3
+ describe "Super admin mode" do
5
4
  around :each do |example|
6
- Celluloid.boot
7
- example.run
8
- Celluloid.shutdown
5
+ example.run_with_retry retry: 10
9
6
  end
10
7
 
11
8
  before(:each) do
12
- Pubnub::Client.any_instance.stub(:sdk_version).and_return('PubNub-Ruby/4.0.16')
9
+ Pubnub::Client.any_instance.stub(:sdk_version).and_return("PubNub-Ruby/4.0.16")
13
10
 
14
11
  @pubnub = Pubnub.new(
15
- subscribe_key: 'sub-c-f9f24520-9c56-11e6-a681-02ee2ddab7fe',
16
- publish_key: 'pub-c-9bb9ae77-a60c-4788-96ab-75cbe5d5dd11',
17
- secret_key: 'sec-c-MjZkYmQyMDUtYmRhZi00ZDY3LThjZGQtNjU2NmNjNmJkODM3',
18
- uuid: 'ruby-test',
19
- reconnect_interval: 0,
20
- ssl: true
12
+ subscribe_key: "sub-c-f9f24520-9c56-11e6-a681-02ee2ddab7fe",
13
+ publish_key: "pub-c-9bb9ae77-a60c-4788-96ab-75cbe5d5dd11",
14
+ secret_key: "sec-c-MjZkYmQyMDUtYmRhZi00ZDY3LThjZGQtNjU2NmNjNmJkODM3",
15
+ uuid: "ruby-test",
16
+ reconnect_interval: 0,
17
+ ssl: true,
21
18
  )
22
19
  end
23
20
 
24
- describe 'OpenSSL error' do
25
- it 'is caught' do
21
+ describe "OpenSSL error" do
22
+ it "is caught" do
26
23
  Pubnub::Publish.any_instance.stub(:current_time).and_return(1480343560)
27
24
  Pubnub::Publish.any_instance.stub(:send_request).and_return(OpenSSL::SSL::SSLError.new)
28
25
  Pubnub::Client.any_instance.stub(:generate_ortt).and_return(14803435605315392)
29
26
 
30
- VCR.use_cassette('lib/ssl-error', record: :once) do
27
+ VCR.use_cassette("lib/ssl-error", record: :once) do
31
28
  pub = @pubnub.publish(channel: :demo, message: :demo)
32
29
  expect(pub.value.status[:category]).to eq Pubnub::Constants::SSL_ERROR
33
30
  end
34
31
  end
35
32
  end
36
-
37
- end
33
+ end
@@ -1,166 +1,158 @@
1
- require 'spec_helper'
2
-
3
- describe 'Super admin mode' do
1
+ require "spec_helper"
4
2
 
3
+ describe "Super admin mode" do
5
4
  around :each do |example|
6
- Celluloid.boot
7
- example.run
8
- Celluloid.shutdown
5
+ example.run_with_retry retry: 10
9
6
  end
10
7
 
11
8
  before(:each) do
12
- Pubnub::Client.any_instance.stub(:sdk_version).and_return('PubNub-Ruby/4.0.10')
9
+ Pubnub::Client.any_instance.stub(:sdk_version).and_return("PubNub-Ruby/4.0.10")
13
10
 
14
- @messages = []
15
- @statuses = []
11
+ @messages = []
12
+ @statuses = []
16
13
  @presences = []
17
14
 
18
15
  @callbacks = Pubnub::SubscribeCallback.new(
19
- message: ->(envelope) { @messages << envelope },
20
- presence: ->(envelope) { @presences << envelope },
21
- status: ->(envelope) { @statuses << envelope }
16
+ message: -> (envelope) { @messages << envelope },
17
+ presence: -> (envelope) { @presences << envelope },
18
+ status: -> (envelope) { @statuses << envelope },
22
19
  )
23
20
 
24
21
  @pubnub = Pubnub.new(
25
- subscribe_key: 'sub-c-f9f24520-9c56-11e6-a681-02ee2ddab7fe',
26
- publish_key: 'pub-c-9bb9ae77-a60c-4788-96ab-75cbe5d5dd11',
27
- secret_key: 'sec-c-MjZkYmQyMDUtYmRhZi00ZDY3LThjZGQtNjU2NmNjNmJkODM3',
28
- uuid: 'ruby-test',
29
- reconnect_interval: 0
22
+ subscribe_key: "sub-c-f9f24520-9c56-11e6-a681-02ee2ddab7fe",
23
+ publish_key: "pub-c-9bb9ae77-a60c-4788-96ab-75cbe5d5dd11",
24
+ secret_key: "sec-c-MjZkYmQyMDUtYmRhZi00ZDY3LThjZGQtNjU2NmNjNmJkODM3",
25
+ uuid: "ruby-test",
26
+ reconnect_interval: 0,
30
27
  )
31
28
 
32
29
  @pubnub.add_listener(callback: @callbacks)
33
30
  end
34
31
 
35
- it 'works with channel registration' do
32
+ it "works with channel registration" do
36
33
  Pubnub::ChannelRegistration.any_instance.stub(:current_time).and_return(1477672650)
37
34
 
38
- VCR.use_cassette('lib/super_admin/cg', record: :once) do
35
+ VCR.use_cassette("lib/super_admin/cg", record: :once) do
39
36
  envelope = @pubnub.channel_registration(
40
- action: :add,
41
- channel: :demo,
42
- group: :demo
37
+ action: :add,
38
+ channel: :demo,
39
+ group: :demo,
43
40
  ).value
44
41
 
45
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
42
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
46
43
  end
47
44
  end
48
45
 
49
- it 'works with here_now' do
46
+ it "works with here_now" do
50
47
  Pubnub::HereNow.any_instance.stub(:current_time).and_return(1477672650)
51
48
 
52
- VCR.use_cassette('lib/super_admin/here_now', record: :once) do
49
+ VCR.use_cassette("lib/super_admin/here_now", record: :once) do
53
50
  envelope = @pubnub.here_now(
54
- channel: :demo
51
+ channel: :demo,
55
52
  ).value
56
53
 
57
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
54
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
58
55
  end
59
56
  end
60
57
 
61
- it 'works with history' do
58
+ it "works with history" do
62
59
  Pubnub::History.any_instance.stub(:current_time).and_return(1477672650)
63
60
 
64
- VCR.use_cassette('lib/super_admin/history', record: :once) do
61
+ VCR.use_cassette("lib/super_admin/history", record: :once) do
65
62
  envelope = @pubnub.history(
66
- channel: :demo
63
+ channel: :demo,
67
64
  ).value
68
65
 
69
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
70
-
66
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
71
67
  end
72
68
  end
73
69
 
74
- it 'works with leave' do
70
+ it "works with leave" do
75
71
  Pubnub::Leave.any_instance.stub(:current_time).and_return(1477907746)
76
72
 
77
- VCR.use_cassette('lib/super_admin/leave', record: :once) do
73
+ VCR.use_cassette("lib/super_admin/leave", record: :once) do
78
74
  envelope = @pubnub.leave(
79
- channel: :demo
75
+ channel: :demo,
80
76
  ).value
81
77
 
82
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
78
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
83
79
  end
84
80
  end
85
81
 
86
- it 'works with presence' do
87
- VCR.use_cassette('lib/super_admin/presence', record: :once) do
82
+ it "works with presence" do
83
+ VCR.use_cassette("lib/super_admin/presence", record: :once) do
88
84
  Pubnub::Subscribe.any_instance.stub(:current_time).and_return(1477921137)
89
85
 
90
86
  @pubnub.presence(channel: :demo)
91
87
 
92
88
  eventually do
93
89
  envelope = @presences.first
94
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
90
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
95
91
  end
96
-
97
92
  end
98
93
  end
99
94
 
100
- it 'works with publish' do
95
+ it "works with publish" do
101
96
  Pubnub::Publish.any_instance.stub(:current_time).and_return(1477919007)
102
97
  Pubnub::Client.any_instance.stub(:generate_ortt).and_return(14779190077911314)
103
98
 
104
- VCR.use_cassette('lib/super_admin/publish', record: :once) do
99
+ VCR.use_cassette("lib/super_admin/publish", record: :once) do
105
100
  envelope = @pubnub.publish(
106
- channel: 'demo',
107
- message: 'whatever',
108
- http_sync: true
101
+ channel: "demo",
102
+ message: "whatever",
103
+ http_sync: true,
109
104
  )
110
105
 
111
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
106
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
112
107
  expect(envelope).to be_an_instance_of(Pubnub::Envelope)
113
108
  end
114
109
  end
115
110
 
116
- it 'works with state' do
111
+ it "works with state" do
117
112
  Pubnub::State.any_instance.stub(:current_time).and_return(1477672672)
118
113
 
119
- VCR.use_cassette('lib/super_admin/state', record: :once) do
114
+ VCR.use_cassette("lib/super_admin/state", record: :once) do
120
115
  envelope = @pubnub.state(
121
- channel: :demo,
122
- uuid: :whatever
116
+ channel: :demo,
117
+ uuid: :whatever,
123
118
  ).value
124
119
 
125
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
126
-
120
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
127
121
  end
128
122
  end
129
123
 
130
- it 'works with subscribe' do
124
+ it "works with subscribe" do
131
125
  Pubnub::Subscribe.any_instance.stub(:current_time).and_return(1477921157)
132
126
 
133
-
134
- VCR.use_cassette('lib/super_admin/subscribe', record: :once) do
127
+ VCR.use_cassette("lib/super_admin/subscribe", record: :once) do
135
128
  @pubnub.subscribe(channel: :demo)
136
129
 
137
130
  eventually do
138
131
  envelope = @messages.first
139
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
132
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
140
133
  end
141
134
  end
142
135
  end
143
136
 
144
- it 'works with time' do
137
+ it "works with time" do
145
138
  Pubnub::Time.any_instance.stub(:current_time).and_return(1477672693)
146
139
 
147
- VCR.use_cassette('lib/super_admin/time', record: :once) do
140
+ VCR.use_cassette("lib/super_admin/time", record: :once) do
148
141
  envelope = @pubnub.time.value
149
142
 
150
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
143
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
151
144
  end
152
145
  end
153
146
 
154
- it 'works with where_now' do
147
+ it "works with where_now" do
155
148
  Pubnub::WhereNow.any_instance.stub(:current_time).and_return(1477672693)
156
-
157
- VCR.use_cassette('lib/super_admin/where_now', record: :once) do
149
+
150
+ VCR.use_cassette("lib/super_admin/where_now", record: :once) do
158
151
  envelope = @pubnub.where_now(
159
- uuid: 'ruby-test'
152
+ uuid: "ruby-test",
160
153
  ).value
161
154
 
162
- expect(envelope.status[:client_request].to_s.index('&signature=')).to be_truthy
163
-
155
+ expect(envelope.status[:client_request].to_s.index("&signature=")).to be_truthy
164
156
  end
165
157
  end
166
- end
158
+ end
@@ -1,9 +1,8 @@
1
- require 'spec_helper'
1
+ require "spec_helper"
2
2
 
3
3
  describe Pubnub::UUID do
4
- it 'generates valid UUID' do
5
- expect(Pubnub::UUID.generate)
6
- .to match(
4
+ it "generates valid UUID" do
5
+ expect(Pubnub::UUID.generate).to match(
7
6
  /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}
8
7
  -[0-9a-f]{12}$/x
9
8
  )
@@ -1,4 +1,4 @@
1
- require 'rspec/expectations'
1
+ require "rspec/expectations"
2
2
 
3
3
  RSpec::Matchers.define :satisfies_schema do |expected|
4
4
  match do |actual|
@@ -8,6 +8,6 @@ RSpec::Matchers.define :satisfies_schema do |expected|
8
8
 
9
9
  failure_message do |actual|
10
10
  msg = "expected that given hash will fit the schema.\n"
11
- msg + @check.messages.map { |k,v| "#{k}: #{v}" }.join("\n")
11
+ msg + @check.messages.map { |k, v| "#{k}: #{v}" }.join("\n")
12
12
  end
13
- end
13
+ end
@@ -1,55 +1,34 @@
1
- require 'rubygems'
2
- require 'rr'
3
- require 'stringio'
4
- require 'webmock/rspec'
5
- require 'vcr'
6
- require 'celluloid/current'
7
- require 'celluloid/test'
8
- require 'pry'
9
- require 'rspec/wait'
10
- require 'spec_expectations'
11
-
12
- require 'simplecov'
1
+ require "rubygems"
2
+ require "rr"
3
+ require "stringio"
4
+ require "webmock/rspec"
5
+ require "vcr"
6
+ require "pry"
7
+ require "spec_expectations"
8
+ require "concurrent"
9
+ require "concurrent-edge"
10
+ require "rspec/retry"
11
+ require "simplecov"
13
12
  SimpleCov.start do
14
- add_filter '/spec/'
13
+ add_filter "/spec/"
15
14
  end
16
15
 
17
- require 'pubnub'
18
-
19
- if ENV['CI'] == 'true'
20
- require 'codacy-coverage'
16
+ require "pubnub"
17
+ Pubnub::Constants::DEFAULT_RECONNECT_INTERVAL = 0
18
+ if ENV["CI"] == "true"
19
+ require "codacy-coverage"
21
20
  Codacy::Reporter.start
22
21
  end
23
22
 
24
- Celluloid.task_class = Celluloid::Task::Threaded
25
-
26
- module CelluloidHotFix
27
- # We can't shutdown the actor if there is no actor running.
28
- #
29
- # See https://github.com/celluloid/celluloid/pull/766
30
- def shutdown
31
- super if @actor_system
32
- @actor_system = nil
33
- end
34
-
35
- # We can't verify if the actor is running if there is no actor
36
- # running.
37
- #
38
- # This is a problem generated by the hotfix above.
39
- def running?
40
- super if @actor_system
41
- end
42
- end
43
-
44
- Celluloid.singleton_class.prepend(CelluloidHotFix)
45
-
46
23
  # AsyncHelper allows us to wait for async operations
47
24
  module AsyncHelper
48
25
  def eventually(options = {})
49
26
  timeout = options[:timeout] || 30
50
27
  interval = options[:interval] || 0.1
51
28
  time_limit = Time.now + timeout
52
- loop_it(interval, time_limit) do yield end
29
+ loop_it(interval, time_limit) do
30
+ yield
31
+ end
53
32
  end
54
33
 
55
34
  def loop_it(interval, time_limit)
@@ -73,9 +52,9 @@ RSpec.configure do |config|
73
52
  config.mock_framework = :rspec
74
53
  config.tty = true
75
54
 
76
- logfile = File.open(File.expand_path('../../test.log', __FILE__), 'a')
55
+ logfile = File.open(File.expand_path("../../test.log", __FILE__), "a")
77
56
  logfile.sync = true
78
- Celluloid.logger = Logger.new(logfile)
57
+ Concurrent.global_logger = Logger.new(logfile)
79
58
 
80
59
  # config.around(:each) do |example|
81
60
  # if example.metadata[:disable_vcr]
@@ -87,13 +66,17 @@ RSpec.configure do |config|
87
66
  end
88
67
 
89
68
  VCR.configure do |c|
90
- c.cassette_library_dir = 'fixtures/vcr_cassettes'
69
+ ignored_params = [
70
+ :pnsdk, :uuid, :ortt, :seqn, :t,
71
+ :l_pres, :l_pub, :l_pres, :l_hist, :l_cg, :l_time
72
+ ]
73
+ c.cassette_library_dir = "fixtures/vcr_cassettes"
91
74
  c.hook_into :webmock
92
75
  c.allow_http_connections_when_no_cassette = false
93
- c.ignore_hosts 'api.codacy.com'
76
+ c.ignore_hosts "api.codacy.com"
94
77
  c.default_cassette_options = {
95
78
  match_requests_on: [:method,
96
- VCR.request_matchers.uri_without_param(:pnsdk, :uuid, :ortt, :seqn, :t)]
79
+ VCR.request_matchers.uri_without_param(*ignored_params)],
97
80
  }
98
- c.debug_logger = File.open('vcr.log', 'w')
81
+ c.debug_logger = File.open("vcr.log", "w")
99
82
  end
metadata CHANGED
@@ -1,49 +1,57 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pubnub
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.27
4
+ version: 4.0.28
5
5
  platform: ruby
6
6
  authors:
7
7
  - PubNub
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-11-20 00:00:00.000000000 Z
11
+ date: 2018-08-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: celluloid
14
+ name: concurrent-ruby
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0.17'
19
+ version: 1.0.5
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '0.17'
26
+ version: 1.0.5
27
27
  - !ruby/object:Gem::Dependency
28
- name: json
28
+ name: concurrent-ruby-edge
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ">="
32
- - !ruby/object:Gem::Version
33
- version: '1.8'
34
- - - "<"
31
+ - - "~>"
35
32
  - !ruby/object:Gem::Version
36
- version: '3'
33
+ version: 0.3.1
37
34
  type: :runtime
38
35
  prerelease: false
39
36
  version_requirements: !ruby/object:Gem::Requirement
40
37
  requirements:
41
- - - ">="
38
+ - - "~>"
42
39
  - !ruby/object:Gem::Version
43
- version: '1.8'
44
- - - "<"
40
+ version: 0.3.1
41
+ - !ruby/object:Gem::Dependency
42
+ name: dry-validation
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
45
46
  - !ruby/object:Gem::Version
46
- version: '3'
47
+ version: '0.10'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '0.10'
47
55
  - !ruby/object:Gem::Dependency
48
56
  name: httpclient
49
57
  requirement: !ruby/object:Gem::Requirement
@@ -65,19 +73,39 @@ dependencies:
65
73
  - !ruby/object:Gem::Version
66
74
  version: 2.8.3
67
75
  - !ruby/object:Gem::Dependency
68
- name: dry-validation
76
+ name: json
69
77
  requirement: !ruby/object:Gem::Requirement
70
78
  requirements:
71
- - - "~>"
79
+ - - ">="
72
80
  - !ruby/object:Gem::Version
73
- version: '0.10'
81
+ version: '1.8'
82
+ - - "<"
83
+ - !ruby/object:Gem::Version
84
+ version: '3'
74
85
  type: :runtime
75
86
  prerelease: false
76
87
  version_requirements: !ruby/object:Gem::Requirement
77
88
  requirements:
78
- - - "~>"
89
+ - - ">="
79
90
  - !ruby/object:Gem::Version
80
- version: '0.10'
91
+ version: '1.8'
92
+ - - "<"
93
+ - !ruby/object:Gem::Version
94
+ version: '3'
95
+ - !ruby/object:Gem::Dependency
96
+ name: timers
97
+ requirement: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - ">="
100
+ - !ruby/object:Gem::Version
101
+ version: 4.1.1
102
+ type: :runtime
103
+ prerelease: false
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ requirements:
106
+ - - ">="
107
+ - !ruby/object:Gem::Version
108
+ version: 4.1.1
81
109
  - !ruby/object:Gem::Dependency
82
110
  name: bundler
83
111
  requirement: !ruby/object:Gem::Requirement
@@ -10524,6 +10552,8 @@ files:
10524
10552
  - gemfiles/celluloid_018.gemfile.lock
10525
10553
  - gemfiles/celluloid_master.gemfile
10526
10554
  - gemfiles/celluloid_master.gemfile.lock
10555
+ - gemfiles/concurrent-ruby-1.0.5.gem
10556
+ - gemfiles/concurrent-ruby-edge-0.3.1.gem
10527
10557
  - lib/pubnub.rb
10528
10558
  - lib/pubnub/client.rb
10529
10559
  - lib/pubnub/client/events.rb
@@ -10555,9 +10585,9 @@ files:
10555
10585
  - lib/pubnub/events/subscribe.rb
10556
10586
  - lib/pubnub/events/time.rb
10557
10587
  - lib/pubnub/events/where_now.rb
10588
+ - lib/pubnub/format.rb
10558
10589
  - lib/pubnub/formatter.rb
10559
10590
  - lib/pubnub/heart.rb
10560
- - lib/pubnub/message.rb
10561
10591
  - lib/pubnub/origin_manager.rb
10562
10592
  - lib/pubnub/pam.rb
10563
10593
  - lib/pubnub/schemas/envelope_schema.rb
@@ -10660,7 +10690,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
10660
10690
  version: '0'
10661
10691
  requirements: []
10662
10692
  rubyforge_project:
10663
- rubygems_version: 2.6.11
10693
+ rubygems_version: 2.2.2
10664
10694
  signing_key:
10665
10695
  specification_version: 4
10666
10696
  summary: PubNub Official Ruby gem.