ably-rest 0.8.1 → 0.8.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -13
- data/CHANGELOG.md +45 -0
- data/LICENSE +15 -0
- data/README.md +14 -1
- data/lib/submodules/ably-ruby/CHANGELOG.md +45 -0
- data/lib/submodules/ably-ruby/LICENSE +15 -0
- data/lib/submodules/ably-ruby/README.md +18 -14
- data/lib/submodules/ably-ruby/SPEC.md +482 -336
- data/lib/submodules/ably-ruby/ably.gemspec +1 -1
- data/lib/submodules/ably-ruby/lib/ably.rb +1 -1
- data/lib/submodules/ably-ruby/lib/ably/exceptions.rb +4 -1
- data/lib/submodules/ably-ruby/lib/ably/models/{paginated_resource.rb → paginated_result.rb} +8 -8
- data/lib/submodules/ably-ruby/lib/ably/models/presence_message.rb +1 -1
- data/lib/submodules/ably-ruby/lib/ably/modules/conversions.rb +15 -0
- data/lib/submodules/ably-ruby/lib/ably/modules/encodeable.rb +2 -2
- data/lib/submodules/ably-ruby/lib/ably/modules/event_emitter.rb +8 -8
- data/lib/submodules/ably-ruby/lib/ably/modules/safe_deferrable.rb +15 -3
- data/lib/submodules/ably-ruby/lib/ably/modules/state_emitter.rb +2 -2
- data/lib/submodules/ably-ruby/lib/ably/modules/state_machine.rb +1 -1
- data/lib/submodules/ably-ruby/lib/ably/realtime/channel.rb +2 -4
- data/lib/submodules/ably-ruby/lib/ably/realtime/channel/channel_manager.rb +1 -1
- data/lib/submodules/ably-ruby/lib/ably/realtime/client.rb +4 -4
- data/lib/submodules/ably-ruby/lib/ably/realtime/client/incoming_message_dispatcher.rb +2 -2
- data/lib/submodules/ably-ruby/lib/ably/realtime/connection.rb +2 -2
- data/lib/submodules/ably-ruby/lib/ably/realtime/connection/connection_manager.rb +3 -3
- data/lib/submodules/ably-ruby/lib/ably/realtime/connection/connection_state_machine.rb +1 -1
- data/lib/submodules/ably-ruby/lib/ably/realtime/connection/websocket_transport.rb +2 -2
- data/lib/submodules/ably-ruby/lib/ably/realtime/presence.rb +23 -5
- data/lib/submodules/ably-ruby/lib/ably/realtime/presence/members_map.rb +16 -13
- data/lib/submodules/ably-ruby/lib/ably/rest/channel.rb +3 -2
- data/lib/submodules/ably-ruby/lib/ably/rest/client.rb +2 -2
- data/lib/submodules/ably-ruby/lib/ably/rest/presence.rb +4 -4
- data/lib/submodules/ably-ruby/lib/ably/util/pub_sub.rb +1 -1
- data/lib/submodules/ably-ruby/lib/ably/util/safe_deferrable.rb +1 -1
- data/lib/submodules/ably-ruby/lib/ably/version.rb +1 -1
- data/lib/submodules/ably-ruby/spec/acceptance/realtime/channel_history_spec.rb +1 -1
- data/lib/submodules/ably-ruby/spec/acceptance/realtime/channel_spec.rb +5 -15
- data/lib/submodules/ably-ruby/spec/acceptance/realtime/connection_failures_spec.rb +2 -2
- data/lib/submodules/ably-ruby/spec/acceptance/realtime/connection_spec.rb +16 -14
- data/lib/submodules/ably-ruby/spec/acceptance/realtime/message_spec.rb +91 -8
- data/lib/submodules/ably-ruby/spec/acceptance/realtime/presence_spec.rb +190 -71
- data/lib/submodules/ably-ruby/spec/acceptance/realtime/stats_spec.rb +2 -2
- data/lib/submodules/ably-ruby/spec/acceptance/rest/channel_spec.rb +1 -1
- data/lib/submodules/ably-ruby/spec/acceptance/rest/encoders_spec.rb +1 -1
- data/lib/submodules/ably-ruby/spec/acceptance/rest/message_spec.rb +73 -1
- data/lib/submodules/ably-ruby/spec/acceptance/rest/presence_spec.rb +4 -2
- data/lib/submodules/ably-ruby/spec/unit/models/{paginated_resource_spec.rb → paginated_result_spec.rb} +18 -18
- data/lib/submodules/ably-ruby/spec/unit/modules/event_emitter_spec.rb +27 -27
- data/lib/submodules/ably-ruby/spec/unit/modules/state_emitter_spec.rb +1 -1
- data/lib/submodules/ably-ruby/spec/unit/realtime/channel_spec.rb +2 -2
- data/lib/submodules/ably-ruby/spec/unit/realtime/connection_spec.rb +3 -3
- data/lib/submodules/ably-ruby/spec/unit/realtime/presence_spec.rb +2 -2
- metadata +35 -33
- data/LICENSE.txt +0 -22
- data/lib/submodules/ably-ruby/LICENSE.txt +0 -22
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
data.tar.gz: !binary |-
|
6
|
-
M2Y1NTIxMzM1NmQ2NzllNjE5ZmJiOTMyMGQxYzA5MzBhYzEyZmEwNQ==
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: ef2fa15604f31aba5f195c27fc770e8286e751ba
|
4
|
+
data.tar.gz: 6726fb25c2fd8fecfd120b763838105d213f0d9c
|
7
5
|
SHA512:
|
8
|
-
metadata.gz:
|
9
|
-
|
10
|
-
YzJhMjIwY2UyZmU5ZGI1MmM1ZTBhMDMzNjI4OGY2OGQyOGNjOTU3YmI5NTk1
|
11
|
-
MzhmZTJiYTcyNjI3ZGJlYzk1ZWUyNjBkNTVlM2M4M2QwZGI0OGE=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
MjVkZmM1YmExMjVmOTNmZmVlZjhkYTlmMDgwMjdjYTZhOGE2ZmE4OWQwMzhi
|
14
|
-
YzZmZmVjNTJkYzBmOGYyYjYzM2ZjNTYwZDkwNDRmOTJiZjU4NDJiOTUzM2Y3
|
15
|
-
YzEyNjcxOWIyYjRiNTM4MDUyODM0ZjExZGRlOGVhODNkNWQ4Njc=
|
6
|
+
metadata.gz: b5450fca1fe779000c26bce9360c70d3fce19369e7d06d75cb701613e16848922b3db3f8653a5e54748ff7142d03b8da5aab0908a2105832b3d5f951855aedb6
|
7
|
+
data.tar.gz: f762c928f040729a63c535c3a6ea17a0fa6af63877b1d7d7e0451c6fb55db66a2b40dcdf4d8110cb2defdcf8093921ce053b73b70a5295a6b0fc5c3f1fbbd9f3
|
data/CHANGELOG.md
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
# Change Log
|
2
|
+
|
3
|
+
**Merged pull requests:**
|
4
|
+
|
5
|
+
- Ensure files are required in a consistent order [\#51](https://github.com/ably/ably-ruby/pull/51) ([SimonWoolf](https://github.com/SimonWoolf))
|
6
|
+
|
7
|
+
## [v0.8.2](https://github.com/ably/ably-ruby/tree/v0.8.2) (2015-05-20)
|
8
|
+
|
9
|
+
[Full Changelog](https://github.com/ably/ably-ruby/compare/v0.8.1...v0.8.2)
|
10
|
+
|
11
|
+
**Implemented enhancements:**
|
12
|
+
|
13
|
+
- Ensure Array object can be used in place of Hash for payload [\#44](https://github.com/ably/ably-ruby/issues/44)
|
14
|
+
|
15
|
+
- Change connect\_automatically option to auto\_connect for consistency [\#42](https://github.com/ably/ably-ruby/issues/42)
|
16
|
+
|
17
|
+
- Rename PaginatedResource to PaginatedResult for consistency [\#40](https://github.com/ably/ably-ruby/issues/40)
|
18
|
+
|
19
|
+
- EventEmitter should use `emit` not `trigger` to be consistent with other libs [\#31](https://github.com/ably/ably-ruby/issues/31)
|
20
|
+
|
21
|
+
- Add exceptions when data attribute for messages/presence is not String, Binary or JSON data [\#4](https://github.com/ably/ably-ruby/issues/4)
|
22
|
+
|
23
|
+
- Auth Callback and Auth URL should support tokens as well as token requests [\#2](https://github.com/ably/ably-ruby/issues/2)
|
24
|
+
|
25
|
+
**Closed issues:**
|
26
|
+
|
27
|
+
- Realtime Presence\#get does not wait by default [\#47](https://github.com/ably/ably-ruby/issues/47)
|
28
|
+
|
29
|
+
- No implicit attach when accessing channel.presence [\#45](https://github.com/ably/ably-ruby/issues/45)
|
30
|
+
|
31
|
+
**Merged pull requests:**
|
32
|
+
|
33
|
+
- Reject invalid payload type [\#48](https://github.com/ably/ably-ruby/pull/48) ([mattheworiordan](https://github.com/mattheworiordan))
|
34
|
+
|
35
|
+
## [v0.8.1](https://github.com/ably/ably-ruby/tree/v0.8.1) (2015-04-23)
|
36
|
+
|
37
|
+
[Full Changelog](https://github.com/ably/ably-ruby/compare/v0.8.0...v0.8.1)
|
38
|
+
|
39
|
+
## [v0.8.0](https://github.com/ably/ably-ruby/tree/v0.8.0) (2015-04-23)
|
40
|
+
|
41
|
+
[Initial implementation of client library specification 0.8](http://docs.ably.io/client-lib-development-guide/features/)
|
42
|
+
|
43
|
+
[Full Changelog](https://github.com/ably/ably-ruby/compare/v0.7.6...v0.8.0)
|
44
|
+
|
45
|
+
\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
|
data/LICENSE
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
Copyright (c) 2015 Ably
|
2
|
+
|
3
|
+
Copyright 2015 Ably Real-time Ltd
|
4
|
+
|
5
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
you may not use this file except in compliance with the License.
|
7
|
+
You may obtain a copy of the License at
|
8
|
+
|
9
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
|
11
|
+
Unless required by applicable law or agreed to in writing, software
|
12
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
See the License for the specific language governing permissions and
|
15
|
+
limitations under the License.
|
data/README.md
CHANGED
@@ -91,10 +91,23 @@ stats.first = #<Ably::Models::Stat ...>
|
|
91
91
|
client.time #=> 2013-12-12 14:23:34 +0000
|
92
92
|
```
|
93
93
|
|
94
|
+
## Support, feedback and troubleshooting
|
95
|
+
|
96
|
+
Please visit http://support.ably.io/ for access to our knowledgebase and to ask for any assistance.
|
97
|
+
|
98
|
+
You can also view the [community reported Github issues](https://github.com/ably/ably-ruby-rest/issues).
|
99
|
+
|
100
|
+
To see what has changed in recent versions of Bundler, see the [CHANGELOG](CHANGELOG.md).
|
101
|
+
|
94
102
|
## Contributing
|
95
103
|
|
96
104
|
1. Fork it
|
97
105
|
2. Create your feature branch (`git checkout -b my-new-feature`)
|
98
106
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
107
|
+
4. Ensure you have added suitable tests and the test suite is passing(`bundle exec rspec`)
|
99
108
|
4. Push to the branch (`git push origin my-new-feature`)
|
100
|
-
5. Create new Pull Request
|
109
|
+
5. Create a new Pull Request
|
110
|
+
|
111
|
+
## License
|
112
|
+
|
113
|
+
Copyright (c) 2015 Ably Real-time Ltd, Licensed under the Apache License, Version 2.0. Refer to [LICENSE](LICENSE) for the license terms.
|
@@ -0,0 +1,45 @@
|
|
1
|
+
# Change Log
|
2
|
+
|
3
|
+
**Merged pull requests:**
|
4
|
+
|
5
|
+
- Ensure files are required in a consistent order [\#51](https://github.com/ably/ably-ruby/pull/51) ([SimonWoolf](https://github.com/SimonWoolf))
|
6
|
+
|
7
|
+
## [v0.8.2](https://github.com/ably/ably-ruby/tree/v0.8.2) (2015-05-20)
|
8
|
+
|
9
|
+
[Full Changelog](https://github.com/ably/ably-ruby/compare/v0.8.1...v0.8.2)
|
10
|
+
|
11
|
+
**Implemented enhancements:**
|
12
|
+
|
13
|
+
- Ensure Array object can be used in place of Hash for payload [\#44](https://github.com/ably/ably-ruby/issues/44)
|
14
|
+
|
15
|
+
- Change connect\_automatically option to auto\_connect for consistency [\#42](https://github.com/ably/ably-ruby/issues/42)
|
16
|
+
|
17
|
+
- Rename PaginatedResource to PaginatedResult for consistency [\#40](https://github.com/ably/ably-ruby/issues/40)
|
18
|
+
|
19
|
+
- EventEmitter should use `emit` not `trigger` to be consistent with other libs [\#31](https://github.com/ably/ably-ruby/issues/31)
|
20
|
+
|
21
|
+
- Add exceptions when data attribute for messages/presence is not String, Binary or JSON data [\#4](https://github.com/ably/ably-ruby/issues/4)
|
22
|
+
|
23
|
+
- Auth Callback and Auth URL should support tokens as well as token requests [\#2](https://github.com/ably/ably-ruby/issues/2)
|
24
|
+
|
25
|
+
**Closed issues:**
|
26
|
+
|
27
|
+
- Realtime Presence\#get does not wait by default [\#47](https://github.com/ably/ably-ruby/issues/47)
|
28
|
+
|
29
|
+
- No implicit attach when accessing channel.presence [\#45](https://github.com/ably/ably-ruby/issues/45)
|
30
|
+
|
31
|
+
**Merged pull requests:**
|
32
|
+
|
33
|
+
- Reject invalid payload type [\#48](https://github.com/ably/ably-ruby/pull/48) ([mattheworiordan](https://github.com/mattheworiordan))
|
34
|
+
|
35
|
+
## [v0.8.1](https://github.com/ably/ably-ruby/tree/v0.8.1) (2015-04-23)
|
36
|
+
|
37
|
+
[Full Changelog](https://github.com/ably/ably-ruby/compare/v0.8.0...v0.8.1)
|
38
|
+
|
39
|
+
## [v0.8.0](https://github.com/ably/ably-ruby/tree/v0.8.0) (2015-04-23)
|
40
|
+
|
41
|
+
[Initial implementation of client library specification 0.8](http://docs.ably.io/client-lib-development-guide/features/)
|
42
|
+
|
43
|
+
[Full Changelog](https://github.com/ably/ably-ruby/compare/v0.7.6...v0.8.0)
|
44
|
+
|
45
|
+
\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
|
@@ -0,0 +1,15 @@
|
|
1
|
+
Copyright (c) 2015 Ably
|
2
|
+
|
3
|
+
Copyright 2015 Ably Real-time Ltd
|
4
|
+
|
5
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
you may not use this file except in compliance with the License.
|
7
|
+
You may obtain a copy of the License at
|
8
|
+
|
9
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
|
11
|
+
Unless required by applicable law or agreed to in writing, software
|
12
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
See the License for the specific language governing permissions and
|
15
|
+
limitations under the License.
|
@@ -103,11 +103,11 @@ channel.publish('greeting', 'Hello World!')
|
|
103
103
|
|
104
104
|
```ruby
|
105
105
|
channel.history do |messages_page|
|
106
|
-
messages_page #=> #<Ably::Models::
|
106
|
+
messages_page #=> #<Ably::Models::PaginatedResult ...>
|
107
107
|
messages_page.items.first # #<Ably::Models::Message ...>
|
108
108
|
messages_page.items.first.data # payload for the message
|
109
109
|
messages_page.items.length # number of messages in the current page of history
|
110
|
-
messages_page.next # retrieves the next page => #<Ably::Models::
|
110
|
+
messages_page.next # retrieves the next page => #<Ably::Models::PaginatedResult ...>
|
111
111
|
messages_page.has_next? # false, there are more pages
|
112
112
|
end
|
113
113
|
```
|
@@ -127,7 +127,7 @@ channel.presence.history do |presence_page|
|
|
127
127
|
presence_page.items.first.action # Any of :enter, :update or :leave
|
128
128
|
presence_page.items.first.client_id # client ID of member
|
129
129
|
presence_page.items.first.data # optional data payload of member
|
130
|
-
presence_page.next # retrieves the next page => #<Ably::Models::
|
130
|
+
presence_page.next # retrieves the next page => #<Ably::Models::PaginatedResult ...>
|
131
131
|
end
|
132
132
|
```
|
133
133
|
|
@@ -153,30 +153,30 @@ channel.publish('myEvent', 'Hello!') #=> true
|
|
153
153
|
### Querying the History
|
154
154
|
|
155
155
|
```ruby
|
156
|
-
messages_page = channel.history #=> #<Ably::Models::
|
156
|
+
messages_page = channel.history #=> #<Ably::Models::PaginatedResult ...>
|
157
157
|
messages_page.items.first #=> #<Ably::Models::Message ...>
|
158
158
|
messages_page.items.first.data # payload for the message
|
159
|
-
messages_page.next # retrieves the next page => #<Ably::Models::
|
159
|
+
messages_page.next # retrieves the next page => #<Ably::Models::PaginatedResult ...>
|
160
160
|
messages_page.has_next? # false, there are more pages
|
161
161
|
```
|
162
162
|
|
163
163
|
### Presence on a channel
|
164
164
|
|
165
165
|
```ruby
|
166
|
-
members_page = channel.presence.get # => #<Ably::Models::
|
166
|
+
members_page = channel.presence.get # => #<Ably::Models::PaginatedResult ...>
|
167
167
|
members_page.items.first # first member present in this page => #<Ably::Models::PresenceMessage ...>
|
168
168
|
members_page.items.first.client_id # client ID of first member present
|
169
|
-
members_page.next # retrieves the next page => #<Ably::Models::
|
169
|
+
members_page.next # retrieves the next page => #<Ably::Models::PaginatedResult ...>
|
170
170
|
members_page.has_next? # false, there are more pages
|
171
171
|
```
|
172
172
|
|
173
173
|
### Querying the Presence History
|
174
174
|
|
175
175
|
```ruby
|
176
|
-
presence_page = channel.presence.history #=> #<Ably::Models::
|
176
|
+
presence_page = channel.presence.history #=> #<Ably::Models::PaginatedResult ...>
|
177
177
|
presence_page.items.first #=> #<Ably::Models::PresenceMessage ...>
|
178
178
|
presence_page.items.first.client_id # client ID of first member
|
179
|
-
presence_page.next # retrieves the next page => #<Ably::Models::
|
179
|
+
presence_page.next # retrieves the next page => #<Ably::Models::PaginatedResult ...>
|
180
180
|
```
|
181
181
|
|
182
182
|
### Generate Token and Token Request
|
@@ -200,9 +200,9 @@ token = client.auth.create_token_request
|
|
200
200
|
### Fetching your application's stats
|
201
201
|
|
202
202
|
```ruby
|
203
|
-
stats_page = client.stats #=> #<Ably::Models::
|
203
|
+
stats_page = client.stats #=> #<Ably::Models::PaginatedResult ...>
|
204
204
|
stats_page.items.first = #<Ably::Models::Stats ...>
|
205
|
-
stats_page.next # retrieves the next page => #<Ably::Models::
|
205
|
+
stats_page.next # retrieves the next page => #<Ably::Models::PaginatedResult ...>
|
206
206
|
```
|
207
207
|
|
208
208
|
### Fetching the Ably service time
|
@@ -215,9 +215,13 @@ client.time #=> 2013-12-12 14:23:34 +0000
|
|
215
215
|
|
216
216
|
If you only need to use the REST features of this library and do not want EventMachine as a dependency, then you should use the [Ably Ruby REST gem](https://rubygems.org/gems/ably-rest).
|
217
217
|
|
218
|
-
## Support and
|
218
|
+
## Support, feedback and troubleshooting
|
219
219
|
|
220
|
-
Please visit
|
220
|
+
Please visit http://support.ably.io/ for access to our knowledgebase and to ask for any assistance.
|
221
|
+
|
222
|
+
You can also view the [community reported Github issues](https://github.com/ably/ably-ruby/issues).
|
223
|
+
|
224
|
+
To see what has changed in recent versions of Bundler, see the [CHANGELOG](CHANGELOG.md).
|
221
225
|
|
222
226
|
## Contributing
|
223
227
|
|
@@ -230,4 +234,4 @@ Please visit https://support.ably.io/ for access to our knowledgebase and to ask
|
|
230
234
|
|
231
235
|
## License
|
232
236
|
|
233
|
-
Copyright (c) 2015 Ably, Licensed under
|
237
|
+
Copyright (c) 2015 Ably Real-time Ltd, Licensed under the Apache License, Version 2.0. Refer to [LICENSE](LICENSE) for the license terms.
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# Ably Realtime & REST Client Library 0.8.
|
1
|
+
# Ably Realtime & REST Client Library 0.8.2 Specification
|
2
2
|
|
3
3
|
### Ably::Realtime::Channel#history
|
4
4
|
_(see [spec/acceptance/realtime/channel_history_spec.rb](./spec/acceptance/realtime/channel_history_spec.rb))_
|
@@ -27,82 +27,81 @@ _(see [spec/acceptance/realtime/channel_history_spec.rb](./spec/acceptance/realt
|
|
27
27
|
_(see [spec/acceptance/realtime/channel_spec.rb](./spec/acceptance/realtime/channel_spec.rb))_
|
28
28
|
* using JSON and MsgPack protocol
|
29
29
|
* initialization
|
30
|
-
* with :
|
30
|
+
* with :auto_connect option set to false on connection
|
31
31
|
* [remains initialized when accessing a channel](./spec/acceptance/realtime/channel_spec.rb#L21)
|
32
32
|
* [opens a connection implicitly on #attach](./spec/acceptance/realtime/channel_spec.rb#L29)
|
33
|
-
* [opens a connection implicitly when accessing #presence](./spec/acceptance/realtime/channel_spec.rb#L36)
|
34
33
|
* #attach
|
35
|
-
* [emits attaching then attached events](./spec/acceptance/realtime/channel_spec.rb#
|
36
|
-
* [ignores subsequent #attach calls but calls the success callback if provided](./spec/acceptance/realtime/channel_spec.rb#
|
37
|
-
* [attaches to a channel](./spec/acceptance/realtime/channel_spec.rb#
|
38
|
-
* [attaches to a channel and calls the provided block](./spec/acceptance/realtime/channel_spec.rb#
|
39
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/channel_spec.rb#
|
40
|
-
* [calls the SafeDeferrable callback on success](./spec/acceptance/realtime/channel_spec.rb#
|
34
|
+
* [emits attaching then attached events](./spec/acceptance/realtime/channel_spec.rb#L39)
|
35
|
+
* [ignores subsequent #attach calls but calls the success callback if provided](./spec/acceptance/realtime/channel_spec.rb#L49)
|
36
|
+
* [attaches to a channel](./spec/acceptance/realtime/channel_spec.rb#L62)
|
37
|
+
* [attaches to a channel and calls the provided block](./spec/acceptance/realtime/channel_spec.rb#L70)
|
38
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/channel_spec.rb#L77)
|
39
|
+
* [calls the SafeDeferrable callback on success](./spec/acceptance/realtime/channel_spec.rb#L82)
|
41
40
|
* when state is :failed
|
42
|
-
* [reattaches](./spec/acceptance/realtime/channel_spec.rb#
|
41
|
+
* [reattaches](./spec/acceptance/realtime/channel_spec.rb#L93)
|
43
42
|
* when state is :detaching
|
44
|
-
* [moves straight to attaching and skips detached](./spec/acceptance/realtime/channel_spec.rb#
|
43
|
+
* [moves straight to attaching and skips detached](./spec/acceptance/realtime/channel_spec.rb#L106)
|
45
44
|
* with many connections and many channels on each simultaneously
|
46
|
-
* [attaches all channels](./spec/acceptance/realtime/channel_spec.rb#
|
45
|
+
* [attaches all channels](./spec/acceptance/realtime/channel_spec.rb#L132)
|
47
46
|
* failure as a result of insufficient key permissions
|
48
|
-
* [
|
49
|
-
* [calls the errback of the returned Deferrable](./spec/acceptance/realtime/channel_spec.rb#
|
50
|
-
* [
|
51
|
-
* [updates the error_reason](./spec/acceptance/realtime/channel_spec.rb#
|
47
|
+
* [emits failed event](./spec/acceptance/realtime/channel_spec.rb#L155)
|
48
|
+
* [calls the errback of the returned Deferrable](./spec/acceptance/realtime/channel_spec.rb#L164)
|
49
|
+
* [emits an error event](./spec/acceptance/realtime/channel_spec.rb#L172)
|
50
|
+
* [updates the error_reason](./spec/acceptance/realtime/channel_spec.rb#L181)
|
52
51
|
* and subsequent authorisation with suitable permissions
|
53
|
-
* [attaches to the channel successfully and resets the channel error_reason](./spec/acceptance/realtime/channel_spec.rb#
|
52
|
+
* [attaches to the channel successfully and resets the channel error_reason](./spec/acceptance/realtime/channel_spec.rb#L190)
|
54
53
|
* #detach
|
55
|
-
* [detaches from a channel](./spec/acceptance/realtime/channel_spec.rb#
|
56
|
-
* [detaches from a channel and calls the provided block](./spec/acceptance/realtime/channel_spec.rb#
|
57
|
-
* [emits :detaching then :detached events](./spec/acceptance/realtime/channel_spec.rb#
|
58
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/channel_spec.rb#
|
59
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/channel_spec.rb#
|
54
|
+
* [detaches from a channel](./spec/acceptance/realtime/channel_spec.rb#L212)
|
55
|
+
* [detaches from a channel and calls the provided block](./spec/acceptance/realtime/channel_spec.rb#L222)
|
56
|
+
* [emits :detaching then :detached events](./spec/acceptance/realtime/channel_spec.rb#L231)
|
57
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/channel_spec.rb#L243)
|
58
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/channel_spec.rb#L250)
|
60
59
|
* when state is :failed
|
61
|
-
* [raises an exception](./spec/acceptance/realtime/channel_spec.rb#
|
60
|
+
* [raises an exception](./spec/acceptance/realtime/channel_spec.rb#L263)
|
62
61
|
* when state is :attaching
|
63
|
-
* [moves straight to :detaching state and skips :attached](./spec/acceptance/realtime/channel_spec.rb#
|
62
|
+
* [moves straight to :detaching state and skips :attached](./spec/acceptance/realtime/channel_spec.rb#L274)
|
64
63
|
* when state is :detaching
|
65
|
-
* [ignores subsequent #detach calls but calls the callback if provided](./spec/acceptance/realtime/channel_spec.rb#
|
64
|
+
* [ignores subsequent #detach calls but calls the callback if provided](./spec/acceptance/realtime/channel_spec.rb#L292)
|
66
65
|
* channel recovery in :attaching state
|
67
66
|
* the transport is disconnected before the ATTACHED protocol message is received
|
68
|
-
* PENDING: *[attach times out and fails if not ATTACHED protocol message received](./spec/acceptance/realtime/channel_spec.rb#
|
69
|
-
* PENDING: *[channel is ATTACHED if ATTACHED protocol message is later received](./spec/acceptance/realtime/channel_spec.rb#
|
70
|
-
* PENDING: *[sends an ATTACH protocol message in response to a channel message being received on the attaching channel](./spec/acceptance/realtime/channel_spec.rb#
|
67
|
+
* PENDING: *[attach times out and fails if not ATTACHED protocol message received](./spec/acceptance/realtime/channel_spec.rb#L311)*
|
68
|
+
* PENDING: *[channel is ATTACHED if ATTACHED protocol message is later received](./spec/acceptance/realtime/channel_spec.rb#L312)*
|
69
|
+
* PENDING: *[sends an ATTACH protocol message in response to a channel message being received on the attaching channel](./spec/acceptance/realtime/channel_spec.rb#L313)*
|
71
70
|
* #publish
|
72
71
|
* when attached
|
73
|
-
* [publishes messages](./spec/acceptance/realtime/channel_spec.rb#
|
72
|
+
* [publishes messages](./spec/acceptance/realtime/channel_spec.rb#L319)
|
74
73
|
* when not yet attached
|
75
|
-
* [publishes queued messages once attached](./spec/acceptance/realtime/channel_spec.rb#
|
76
|
-
* [publishes queued messages within a single protocol message](./spec/acceptance/realtime/channel_spec.rb#
|
74
|
+
* [publishes queued messages once attached](./spec/acceptance/realtime/channel_spec.rb#L331)
|
75
|
+
* [publishes queued messages within a single protocol message](./spec/acceptance/realtime/channel_spec.rb#L339)
|
77
76
|
* #subscribe
|
78
77
|
* with an event argument
|
79
|
-
* [subscribes for a single event](./spec/acceptance/realtime/channel_spec.rb#
|
78
|
+
* [subscribes for a single event](./spec/acceptance/realtime/channel_spec.rb#L362)
|
80
79
|
* with no event argument
|
81
|
-
* [subscribes for all events](./spec/acceptance/realtime/channel_spec.rb#
|
80
|
+
* [subscribes for all events](./spec/acceptance/realtime/channel_spec.rb#L372)
|
82
81
|
* many times with different event names
|
83
|
-
* [filters events accordingly to each callback](./spec/acceptance/realtime/channel_spec.rb#
|
82
|
+
* [filters events accordingly to each callback](./spec/acceptance/realtime/channel_spec.rb#L382)
|
84
83
|
* #unsubscribe
|
85
84
|
* with an event argument
|
86
|
-
* [unsubscribes for a single event](./spec/acceptance/realtime/channel_spec.rb#
|
85
|
+
* [unsubscribes for a single event](./spec/acceptance/realtime/channel_spec.rb#L405)
|
87
86
|
* with no event argument
|
88
|
-
* [unsubscribes for a single event](./spec/acceptance/realtime/channel_spec.rb#
|
87
|
+
* [unsubscribes for a single event](./spec/acceptance/realtime/channel_spec.rb#L418)
|
89
88
|
* when connection state changes to
|
90
89
|
* :failed
|
91
90
|
* an :attached channel
|
92
|
-
* [transitions state to :failed](./spec/acceptance/realtime/channel_spec.rb#
|
93
|
-
* [
|
94
|
-
* [updates the channel error_reason](./spec/acceptance/realtime/channel_spec.rb#
|
91
|
+
* [transitions state to :failed](./spec/acceptance/realtime/channel_spec.rb#L441)
|
92
|
+
* [emits an error event on the channel](./spec/acceptance/realtime/channel_spec.rb#L451)
|
93
|
+
* [updates the channel error_reason](./spec/acceptance/realtime/channel_spec.rb#L461)
|
95
94
|
* a :detached channel
|
96
|
-
* [remains in the :detached state](./spec/acceptance/realtime/channel_spec.rb#
|
95
|
+
* [remains in the :detached state](./spec/acceptance/realtime/channel_spec.rb#L473)
|
97
96
|
* a :failed channel
|
98
|
-
* [remains in the :failed state and ignores the failure error](./spec/acceptance/realtime/channel_spec.rb#
|
97
|
+
* [remains in the :failed state and ignores the failure error](./spec/acceptance/realtime/channel_spec.rb#L493)
|
99
98
|
* :closed
|
100
99
|
* an :attached channel
|
101
|
-
* [transitions state to :detached](./spec/acceptance/realtime/channel_spec.rb#
|
100
|
+
* [transitions state to :detached](./spec/acceptance/realtime/channel_spec.rb#L516)
|
102
101
|
* a :detached channel
|
103
|
-
* [remains in the :detached state](./spec/acceptance/realtime/channel_spec.rb#
|
102
|
+
* [remains in the :detached state](./spec/acceptance/realtime/channel_spec.rb#L527)
|
104
103
|
* a :failed channel
|
105
|
-
* [remains in the :failed state and retains the error_reason](./spec/acceptance/realtime/channel_spec.rb#
|
104
|
+
* [remains in the :failed state and retains the error_reason](./spec/acceptance/realtime/channel_spec.rb#L548)
|
106
105
|
|
107
106
|
### Ably::Realtime::Client
|
108
107
|
_(see [spec/acceptance/realtime/client_spec.rb](./spec/acceptance/realtime/client_spec.rb))_
|
@@ -170,7 +169,7 @@ _(see [spec/acceptance/realtime/connection_failures_spec.rb](./spec/acceptance/r
|
|
170
169
|
* when DISCONNECTED ProtocolMessage received from the server
|
171
170
|
* [reconnects automatically and immediately](./spec/acceptance/realtime/connection_failures_spec.rb#L292)
|
172
171
|
* and subsequently fails to reconnect
|
173
|
-
* [retries every
|
172
|
+
* [retries every 15 seconds](./spec/acceptance/realtime/connection_failures_spec.rb#L322)
|
174
173
|
* when websocket transport is closed
|
175
174
|
* [reconnects automatically](./spec/acceptance/realtime/connection_failures_spec.rb#L365)
|
176
175
|
* after successfully reconnecting and resuming
|
@@ -200,7 +199,7 @@ _(see [spec/acceptance/realtime/connection_spec.rb](./spec/acceptance/realtime/c
|
|
200
199
|
* using JSON and MsgPack protocol
|
201
200
|
* intialization
|
202
201
|
* [connects automatically](./spec/acceptance/realtime/connection_spec.rb#L23)
|
203
|
-
* with :
|
202
|
+
* with :auto_connect option set to false
|
204
203
|
* [does not connect automatically](./spec/acceptance/realtime/connection_spec.rb#L35)
|
205
204
|
* [connects when method #connect is called](./spec/acceptance/realtime/connection_spec.rb#L43)
|
206
205
|
* with token auth
|
@@ -231,9 +230,9 @@ _(see [spec/acceptance/realtime/connection_spec.rb](./spec/acceptance/realtime/c
|
|
231
230
|
* PENDING: *[transitions state to failed](./spec/acceptance/realtime/connection_spec.rb#L195)*
|
232
231
|
* initialization state changes
|
233
232
|
* with implicit #connect
|
234
|
-
* [are
|
233
|
+
* [are emitted in order](./spec/acceptance/realtime/connection_spec.rb#L222)
|
235
234
|
* with explicit #connect
|
236
|
-
* [are
|
235
|
+
* [are emitted in order](./spec/acceptance/realtime/connection_spec.rb#L228)
|
237
236
|
* #connect
|
238
237
|
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/connection_spec.rb#L236)
|
239
238
|
* [calls the Deferrable callback on success](./spec/acceptance/realtime/connection_spec.rb#L241)
|
@@ -276,127 +275,145 @@ _(see [spec/acceptance/realtime/connection_spec.rb](./spec/acceptance/realtime/c
|
|
276
275
|
* [catches the exception and logs the error](./spec/acceptance/realtime/connection_spec.rb#L508)
|
277
276
|
* recovery
|
278
277
|
* #recovery_key
|
279
|
-
* [is composed of connection
|
280
|
-
* [is available when connection is in one of the states: connecting, connected, disconnected, suspended, failed](./spec/acceptance/realtime/connection_spec.rb#
|
281
|
-
* [is nil when connection is explicitly CLOSED](./spec/acceptance/realtime/connection_spec.rb#
|
278
|
+
* [is composed of connection key and serial that is kept up to date with each message ACK received](./spec/acceptance/realtime/connection_spec.rb#L545)
|
279
|
+
* [is available when connection is in one of the states: connecting, connected, disconnected, suspended, failed](./spec/acceptance/realtime/connection_spec.rb#L568)
|
280
|
+
* [is nil when connection is explicitly CLOSED](./spec/acceptance/realtime/connection_spec.rb#L592)
|
282
281
|
* opening a new connection using a recently disconnected connection's #recovery_key
|
283
282
|
* connection#id and connection#key after recovery
|
284
|
-
* [remains the same](./spec/acceptance/realtime/connection_spec.rb#
|
283
|
+
* [remains the same](./spec/acceptance/realtime/connection_spec.rb#L606)
|
285
284
|
* when messages have been sent whilst the old connection is disconnected
|
286
285
|
* the new connection
|
287
|
-
* [recovers server-side queued messages](./spec/acceptance/realtime/connection_spec.rb#
|
286
|
+
* [recovers server-side queued messages](./spec/acceptance/realtime/connection_spec.rb#L647)
|
288
287
|
* with :recover option
|
289
288
|
* with invalid syntax
|
290
|
-
* [raises an exception](./spec/acceptance/realtime/connection_spec.rb#
|
289
|
+
* [raises an exception](./spec/acceptance/realtime/connection_spec.rb#L672)
|
291
290
|
* with invalid formatted value sent to server
|
292
|
-
* [
|
291
|
+
* [emits a fatal error on the connection object, sets the #error_reason and disconnects](./spec/acceptance/realtime/connection_spec.rb#L681)
|
293
292
|
* with expired (missing) value sent to server
|
294
|
-
* [
|
293
|
+
* [emits an error on the connection object, sets the #error_reason, yet will connect anyway](./spec/acceptance/realtime/connection_spec.rb#L696)
|
295
294
|
* with many connections simultaneously
|
296
|
-
* [opens each with a unique connection#id and connection#key](./spec/acceptance/realtime/connection_spec.rb#
|
295
|
+
* [opens each with a unique connection#id and connection#key](./spec/acceptance/realtime/connection_spec.rb#L715)
|
297
296
|
* when a state transition is unsupported
|
298
|
-
* [emits a StateChangeError](./spec/acceptance/realtime/connection_spec.rb#
|
297
|
+
* [emits a StateChangeError](./spec/acceptance/realtime/connection_spec.rb#L735)
|
299
298
|
* protocol failure
|
300
299
|
* receiving an invalid ProtocolMessage
|
301
|
-
* [emits an error on the connection and logs a fatal error message](./spec/acceptance/realtime/connection_spec.rb#
|
300
|
+
* [emits an error on the connection and logs a fatal error message](./spec/acceptance/realtime/connection_spec.rb#L751)
|
302
301
|
* undocumented method
|
303
302
|
* #internet_up?
|
304
|
-
* [returns a Deferrable](./spec/acceptance/realtime/connection_spec.rb#
|
303
|
+
* [returns a Deferrable](./spec/acceptance/realtime/connection_spec.rb#L767)
|
305
304
|
* internet up URL protocol
|
306
305
|
* when using TLS for the connection
|
307
|
-
* [uses TLS for the Internet check to https://internet-up.ably-realtime.com/is-the-internet-up.txt](./spec/acceptance/realtime/connection_spec.rb#
|
306
|
+
* [uses TLS for the Internet check to https://internet-up.ably-realtime.com/is-the-internet-up.txt](./spec/acceptance/realtime/connection_spec.rb#L778)
|
308
307
|
* when using a non-secured connection
|
309
|
-
* [uses TLS for the Internet check to http://internet-up.ably-realtime.com/is-the-internet-up.txt](./spec/acceptance/realtime/connection_spec.rb#
|
308
|
+
* [uses TLS for the Internet check to http://internet-up.ably-realtime.com/is-the-internet-up.txt](./spec/acceptance/realtime/connection_spec.rb#L788)
|
310
309
|
* when the Internet is up
|
311
|
-
* [calls the block with true](./spec/acceptance/realtime/connection_spec.rb#
|
312
|
-
* [calls the success callback of the Deferrable](./spec/acceptance/realtime/connection_spec.rb#
|
310
|
+
* [calls the block with true](./spec/acceptance/realtime/connection_spec.rb#L797)
|
311
|
+
* [calls the success callback of the Deferrable](./spec/acceptance/realtime/connection_spec.rb#L804)
|
313
312
|
* when the Internet is down
|
314
|
-
* [calls the block with false](./spec/acceptance/realtime/connection_spec.rb#
|
315
|
-
* [calls the failure callback of the Deferrable](./spec/acceptance/realtime/connection_spec.rb#
|
313
|
+
* [calls the block with false](./spec/acceptance/realtime/connection_spec.rb#L816)
|
314
|
+
* [calls the failure callback of the Deferrable](./spec/acceptance/realtime/connection_spec.rb#L823)
|
316
315
|
|
317
316
|
### Ably::Realtime::Channel Message
|
318
317
|
_(see [spec/acceptance/realtime/message_spec.rb](./spec/acceptance/realtime/message_spec.rb))_
|
319
318
|
* using JSON and MsgPack protocol
|
320
319
|
* [sends a String data payload](./spec/acceptance/realtime/message_spec.rb#L25)
|
320
|
+
* with supported data payload content type
|
321
|
+
* JSON Object (Hash)
|
322
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/realtime/message_spec.rb#L48)
|
323
|
+
* JSON Array
|
324
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/message_spec.rb#L56)
|
325
|
+
* String
|
326
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/message_spec.rb#L64)
|
327
|
+
* Binary
|
328
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/message_spec.rb#L72)
|
329
|
+
* with unsupported data payload content type
|
330
|
+
* Integer
|
331
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/message_spec.rb#L82)
|
332
|
+
* Float
|
333
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/message_spec.rb#L91)
|
334
|
+
* Boolean
|
335
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/message_spec.rb#L100)
|
336
|
+
* False
|
337
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/message_spec.rb#L109)
|
321
338
|
* with ASCII_8BIT message name
|
322
|
-
* [is converted into UTF_8](./spec/acceptance/realtime/message_spec.rb#
|
339
|
+
* [is converted into UTF_8](./spec/acceptance/realtime/message_spec.rb#L118)
|
323
340
|
* when the message publisher has a client_id
|
324
|
-
* [contains a #client_id attribute](./spec/acceptance/realtime/message_spec.rb#
|
341
|
+
* [contains a #client_id attribute](./spec/acceptance/realtime/message_spec.rb#L134)
|
325
342
|
* #connection_id attribute
|
326
343
|
* over realtime
|
327
|
-
* [matches the sender connection#id](./spec/acceptance/realtime/message_spec.rb#
|
344
|
+
* [matches the sender connection#id](./spec/acceptance/realtime/message_spec.rb#L147)
|
328
345
|
* when retrieved over REST
|
329
|
-
* [matches the sender connection#id](./spec/acceptance/realtime/message_spec.rb#
|
346
|
+
* [matches the sender connection#id](./spec/acceptance/realtime/message_spec.rb#L159)
|
330
347
|
* local echo when published
|
331
|
-
* [is enabled by default](./spec/acceptance/realtime/message_spec.rb#
|
348
|
+
* [is enabled by default](./spec/acceptance/realtime/message_spec.rb#L171)
|
332
349
|
* with :echo_messages option set to false
|
333
|
-
* [will not echo messages to the client but will still broadcast messages to other connected clients](./spec/acceptance/realtime/message_spec.rb#
|
350
|
+
* [will not echo messages to the client but will still broadcast messages to other connected clients](./spec/acceptance/realtime/message_spec.rb#L187)
|
334
351
|
* publishing lots of messages across two connections
|
335
|
-
* [sends and receives the messages on both opened connections and calls the success callbacks for each message published](./spec/acceptance/realtime/message_spec.rb#
|
352
|
+
* [sends and receives the messages on both opened connections and calls the success callbacks for each message published](./spec/acceptance/realtime/message_spec.rb#L219)
|
336
353
|
* without suitable publishing permissions
|
337
|
-
* [calls the error callback](./spec/acceptance/realtime/message_spec.rb#
|
354
|
+
* [calls the error callback](./spec/acceptance/realtime/message_spec.rb#L264)
|
338
355
|
* server incorrectly resends a message that was already received by the client library
|
339
|
-
* [discards the message and logs it as an error to the channel](./spec/acceptance/realtime/message_spec.rb#
|
356
|
+
* [discards the message and logs it as an error to the channel](./spec/acceptance/realtime/message_spec.rb#L284)
|
340
357
|
* encoding and decoding encrypted messages
|
341
358
|
* with AES-128-CBC using crypto-data-128.json fixtures
|
342
359
|
* item 0 with encrypted encoding utf-8/cipher+aes-128-cbc/base64
|
343
360
|
* behaves like an Ably encrypter and decrypter
|
344
361
|
* with #publish and #subscribe
|
345
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
346
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
362
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
363
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
347
364
|
* item 1 with encrypted encoding cipher+aes-128-cbc/base64
|
348
365
|
* behaves like an Ably encrypter and decrypter
|
349
366
|
* with #publish and #subscribe
|
350
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
351
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
367
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
368
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
352
369
|
* item 2 with encrypted encoding json/utf-8/cipher+aes-128-cbc/base64
|
353
370
|
* behaves like an Ably encrypter and decrypter
|
354
371
|
* with #publish and #subscribe
|
355
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
356
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
372
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
373
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
357
374
|
* item 3 with encrypted encoding json/utf-8/cipher+aes-128-cbc/base64
|
358
375
|
* behaves like an Ably encrypter and decrypter
|
359
376
|
* with #publish and #subscribe
|
360
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
361
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
377
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
378
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
362
379
|
* with AES-256-CBC using crypto-data-256.json fixtures
|
363
380
|
* item 0 with encrypted encoding utf-8/cipher+aes-256-cbc/base64
|
364
381
|
* behaves like an Ably encrypter and decrypter
|
365
382
|
* with #publish and #subscribe
|
366
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
367
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
383
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
384
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
368
385
|
* item 1 with encrypted encoding cipher+aes-256-cbc/base64
|
369
386
|
* behaves like an Ably encrypter and decrypter
|
370
387
|
* with #publish and #subscribe
|
371
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
372
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
388
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
389
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
373
390
|
* item 2 with encrypted encoding json/utf-8/cipher+aes-256-cbc/base64
|
374
391
|
* behaves like an Ably encrypter and decrypter
|
375
392
|
* with #publish and #subscribe
|
376
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
377
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
393
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
394
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
378
395
|
* item 3 with encrypted encoding json/utf-8/cipher+aes-256-cbc/base64
|
379
396
|
* behaves like an Ably encrypter and decrypter
|
380
397
|
* with #publish and #subscribe
|
381
|
-
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#
|
382
|
-
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#
|
398
|
+
* [encrypts message automatically before they are pushed to the server](./spec/acceptance/realtime/message_spec.rb#L348)
|
399
|
+
* [sends and receives messages that are encrypted & decrypted by the Ably library](./spec/acceptance/realtime/message_spec.rb#L366)
|
383
400
|
* with multiple sends from one client to another
|
384
|
-
* [encrypts and decrypts all messages](./spec/acceptance/realtime/message_spec.rb#
|
401
|
+
* [encrypts and decrypts all messages](./spec/acceptance/realtime/message_spec.rb#L405)
|
385
402
|
* subscribing with a different transport protocol
|
386
|
-
* [delivers a String ASCII-8BIT payload to the receiver](./spec/acceptance/realtime/message_spec.rb#
|
387
|
-
* [delivers a String UTF-8 payload to the receiver](./spec/acceptance/realtime/message_spec.rb#
|
388
|
-
* [delivers a Hash payload to the receiver](./spec/acceptance/realtime/message_spec.rb#
|
403
|
+
* [delivers a String ASCII-8BIT payload to the receiver](./spec/acceptance/realtime/message_spec.rb#L448)
|
404
|
+
* [delivers a String UTF-8 payload to the receiver](./spec/acceptance/realtime/message_spec.rb#L448)
|
405
|
+
* [delivers a Hash payload to the receiver](./spec/acceptance/realtime/message_spec.rb#L448)
|
389
406
|
* publishing on an unencrypted channel and subscribing on an encrypted channel with another client
|
390
|
-
* [does not attempt to decrypt the message](./spec/acceptance/realtime/message_spec.rb#
|
407
|
+
* [does not attempt to decrypt the message](./spec/acceptance/realtime/message_spec.rb#L467)
|
391
408
|
* publishing on an encrypted channel and subscribing on an unencrypted channel with another client
|
392
|
-
* [delivers the message but still encrypted with a value in the #encoding attribute](./spec/acceptance/realtime/message_spec.rb#
|
393
|
-
* [
|
409
|
+
* [delivers the message but still encrypted with a value in the #encoding attribute](./spec/acceptance/realtime/message_spec.rb#L485)
|
410
|
+
* [emits a Cipher error on the channel](./spec/acceptance/realtime/message_spec.rb#L494)
|
394
411
|
* publishing on an encrypted channel and subscribing with a different algorithm on another client
|
395
|
-
* [delivers the message but still encrypted with the cipher detials in the #encoding attribute](./spec/acceptance/realtime/message_spec.rb#
|
396
|
-
* [
|
412
|
+
* [delivers the message but still encrypted with the cipher detials in the #encoding attribute](./spec/acceptance/realtime/message_spec.rb#L516)
|
413
|
+
* [emits a Cipher error on the channel](./spec/acceptance/realtime/message_spec.rb#L525)
|
397
414
|
* publishing on an encrypted channel and subscribing with a different key on another client
|
398
|
-
* [delivers the message but still encrypted with the cipher details in the #encoding attribute](./spec/acceptance/realtime/message_spec.rb#
|
399
|
-
* [
|
415
|
+
* [delivers the message but still encrypted with the cipher details in the #encoding attribute](./spec/acceptance/realtime/message_spec.rb#L547)
|
416
|
+
* [emits a Cipher error on the channel](./spec/acceptance/realtime/message_spec.rb#L558)
|
400
417
|
|
401
418
|
### Ably::Realtime::Presence history
|
402
419
|
_(see [spec/acceptance/realtime/presence_history_spec.rb](./spec/acceptance/realtime/presence_history_spec.rb))_
|
@@ -413,182 +430,293 @@ _(see [spec/acceptance/realtime/presence_history_spec.rb](./spec/acceptance/real
|
|
413
430
|
_(see [spec/acceptance/realtime/presence_spec.rb](./spec/acceptance/realtime/presence_spec.rb))_
|
414
431
|
* using JSON and MsgPack protocol
|
415
432
|
* when attached (but not present) on a presence channel with an anonymous client (no client ID)
|
416
|
-
* [maintains state as other clients enter and leave the channel](./spec/acceptance/realtime/presence_spec.rb#
|
433
|
+
* [maintains state as other clients enter and leave the channel](./spec/acceptance/realtime/presence_spec.rb#L219)
|
417
434
|
* #sync_complete?
|
418
435
|
* when attaching to a channel without any members present
|
419
|
-
* [is true and the presence channel is considered synced immediately](./spec/acceptance/realtime/presence_spec.rb#
|
436
|
+
* [is true and the presence channel is considered synced immediately](./spec/acceptance/realtime/presence_spec.rb#L295)
|
420
437
|
* when attaching to a channel with members present
|
421
|
-
* [is false and the presence channel will subsequently be synced](./spec/acceptance/realtime/presence_spec.rb#
|
438
|
+
* [is false and the presence channel will subsequently be synced](./spec/acceptance/realtime/presence_spec.rb#L304)
|
422
439
|
* 250 existing (present) members on a channel (3 SYNC pages)
|
423
440
|
* requires at least 3 SYNC ProtocolMessages
|
424
441
|
* when a client attaches to the presence channel
|
425
|
-
* [emits :present for each member](./spec/acceptance/realtime/presence_spec.rb#
|
442
|
+
* [emits :present for each member](./spec/acceptance/realtime/presence_spec.rb#L336)
|
426
443
|
* and a member leaves before the SYNC operation is complete
|
427
|
-
* [emits :leave immediately as the member leaves](./spec/acceptance/realtime/presence_spec.rb#
|
428
|
-
* [ignores presence events with timestamps prior to the current :present event in the MembersMap](./spec/acceptance/realtime/presence_spec.rb#
|
429
|
-
* [does not emit :present after the :leave event has been emitted, and that member is not included in the list of members via #get](./spec/acceptance/realtime/presence_spec.rb#
|
444
|
+
* [emits :leave immediately as the member leaves](./spec/acceptance/realtime/presence_spec.rb#L350)
|
445
|
+
* [ignores presence events with timestamps prior to the current :present event in the MembersMap](./spec/acceptance/realtime/presence_spec.rb#L388)
|
446
|
+
* [does not emit :present after the :leave event has been emitted, and that member is not included in the list of members via #get with :wait_for_sync](./spec/acceptance/realtime/presence_spec.rb#L427)
|
430
447
|
* #get
|
431
|
-
*
|
432
|
-
|
433
|
-
|
434
|
-
|
448
|
+
* with :wait_for_sync option set to true
|
449
|
+
* [waits until sync is complete](./spec/acceptance/realtime/presence_spec.rb#L474)
|
450
|
+
* by default
|
451
|
+
* [it does not wait for sync](./spec/acceptance/realtime/presence_spec.rb#L491)
|
435
452
|
* state
|
436
453
|
* once opened
|
437
|
-
* [once opened, enters the :left state if the channel detaches](./spec/acceptance/realtime/presence_spec.rb#
|
454
|
+
* [once opened, enters the :left state if the channel detaches](./spec/acceptance/realtime/presence_spec.rb#L515)
|
438
455
|
* #enter
|
439
|
-
* [allows client_id to be set on enter for anonymous clients](./spec/acceptance/realtime/presence_spec.rb#
|
440
|
-
* [raises an exception if client_id is not set](./spec/acceptance/realtime/presence_spec.rb#
|
456
|
+
* [allows client_id to be set on enter for anonymous clients](./spec/acceptance/realtime/presence_spec.rb#L538)
|
457
|
+
* [raises an exception if client_id is not set](./spec/acceptance/realtime/presence_spec.rb#L585)
|
441
458
|
* data attribute
|
442
459
|
* when provided as argument option to #enter
|
443
|
-
* [remains intact following #leave](./spec/acceptance/realtime/presence_spec.rb#
|
460
|
+
* [remains intact following #leave](./spec/acceptance/realtime/presence_spec.rb#L549)
|
444
461
|
* message #connection_id
|
445
|
-
* [matches the current client connection_id](./spec/acceptance/realtime/presence_spec.rb#
|
462
|
+
* [matches the current client connection_id](./spec/acceptance/realtime/presence_spec.rb#L573)
|
446
463
|
* without necessary capabilities to join presence
|
447
|
-
* [calls the Deferrable errback on capabilities failure](./spec/acceptance/realtime/presence_spec.rb#
|
464
|
+
* [calls the Deferrable errback on capabilities failure](./spec/acceptance/realtime/presence_spec.rb#L597)
|
448
465
|
* it should behave like a public presence method
|
449
466
|
* [raise an exception if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#L44)
|
450
467
|
* [raise an exception if the channel is failed](./spec/acceptance/realtime/presence_spec.rb#L44)
|
451
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#
|
452
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#
|
453
|
-
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#
|
468
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#L157)
|
469
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#L164)
|
470
|
+
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#L174)
|
471
|
+
* with supported data payload content type
|
472
|
+
* JSON Object (Hash)
|
473
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/realtime/presence_spec.rb#L73)
|
474
|
+
* JSON Array
|
475
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L83)
|
476
|
+
* String
|
477
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L93)
|
478
|
+
* Binary
|
479
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L103)
|
480
|
+
* with unsupported data payload content type
|
481
|
+
* Integer
|
482
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L123)
|
483
|
+
* Float
|
484
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L132)
|
485
|
+
* Boolean
|
486
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L141)
|
487
|
+
* False
|
488
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L150)
|
454
489
|
* if connection fails before success
|
455
|
-
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#
|
490
|
+
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#L195)
|
456
491
|
* #update
|
457
|
-
* [without previous #enter automatically enters](./spec/acceptance/realtime/presence_spec.rb#
|
458
|
-
* [updates the data if :data argument provided](./spec/acceptance/realtime/presence_spec.rb#
|
459
|
-
* [updates the data to nil if :data argument is not provided (assumes nil value)](./spec/acceptance/realtime/presence_spec.rb#
|
492
|
+
* [without previous #enter automatically enters](./spec/acceptance/realtime/presence_spec.rb#L609)
|
493
|
+
* [updates the data if :data argument provided](./spec/acceptance/realtime/presence_spec.rb#L634)
|
494
|
+
* [updates the data to nil if :data argument is not provided (assumes nil value)](./spec/acceptance/realtime/presence_spec.rb#L644)
|
460
495
|
* when ENTERED
|
461
|
-
* [has no effect on the state](./spec/acceptance/realtime/presence_spec.rb#
|
496
|
+
* [has no effect on the state](./spec/acceptance/realtime/presence_spec.rb#L619)
|
462
497
|
* it should behave like a public presence method
|
463
498
|
* [raise an exception if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#L44)
|
464
499
|
* [raise an exception if the channel is failed](./spec/acceptance/realtime/presence_spec.rb#L44)
|
465
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#
|
466
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#
|
467
|
-
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#
|
500
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#L157)
|
501
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#L164)
|
502
|
+
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#L174)
|
503
|
+
* with supported data payload content type
|
504
|
+
* JSON Object (Hash)
|
505
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/realtime/presence_spec.rb#L73)
|
506
|
+
* JSON Array
|
507
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L83)
|
508
|
+
* String
|
509
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L93)
|
510
|
+
* Binary
|
511
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L103)
|
512
|
+
* with unsupported data payload content type
|
513
|
+
* Integer
|
514
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L123)
|
515
|
+
* Float
|
516
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L132)
|
517
|
+
* Boolean
|
518
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L141)
|
519
|
+
* False
|
520
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L150)
|
468
521
|
* if connection fails before success
|
469
|
-
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#
|
522
|
+
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#L195)
|
470
523
|
* #leave
|
471
|
-
* [raises an exception if not entered](./spec/acceptance/realtime/presence_spec.rb#
|
524
|
+
* [raises an exception if not entered](./spec/acceptance/realtime/presence_spec.rb#L718)
|
472
525
|
* :data option
|
473
526
|
* when set to a string
|
474
|
-
* [emits the new data for the leave event](./spec/acceptance/realtime/presence_spec.rb#
|
527
|
+
* [emits the new data for the leave event](./spec/acceptance/realtime/presence_spec.rb#L663)
|
475
528
|
* when set to nil
|
476
|
-
* [emits
|
529
|
+
* [emits a nil value for the data attribute when leaving](./spec/acceptance/realtime/presence_spec.rb#L676)
|
477
530
|
* when not passed as an argument
|
478
|
-
* [emits the previously defined value as a convenience](./spec/acceptance/realtime/presence_spec.rb#
|
531
|
+
* [emits the previously defined value as a convenience](./spec/acceptance/realtime/presence_spec.rb#L689)
|
532
|
+
* and sync is complete
|
533
|
+
* [does not cache members that have left](./spec/acceptance/realtime/presence_spec.rb#L702)
|
479
534
|
* it should behave like a public presence method
|
480
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#
|
481
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#
|
482
|
-
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#
|
535
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#L157)
|
536
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#L164)
|
537
|
+
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#L174)
|
538
|
+
* with supported data payload content type
|
539
|
+
* JSON Object (Hash)
|
540
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/realtime/presence_spec.rb#L73)
|
541
|
+
* JSON Array
|
542
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L83)
|
543
|
+
* String
|
544
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L93)
|
545
|
+
* Binary
|
546
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L103)
|
547
|
+
* with unsupported data payload content type
|
548
|
+
* Integer
|
549
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L123)
|
550
|
+
* Float
|
551
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L132)
|
552
|
+
* Boolean
|
553
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L141)
|
554
|
+
* False
|
555
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L150)
|
483
556
|
* if connection fails before success
|
484
|
-
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#
|
557
|
+
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#L195)
|
485
558
|
* :left event
|
486
|
-
* [emits the data defined in enter](./spec/acceptance/realtime/presence_spec.rb#
|
487
|
-
* [emits the data defined in update](./spec/acceptance/realtime/presence_spec.rb#
|
559
|
+
* [emits the data defined in enter](./spec/acceptance/realtime/presence_spec.rb#L727)
|
560
|
+
* [emits the data defined in update](./spec/acceptance/realtime/presence_spec.rb#L738)
|
488
561
|
* entering/updating/leaving presence state on behalf of another client_id
|
489
562
|
* #enter_client
|
490
563
|
* multiple times on the same channel with different client_ids
|
491
|
-
* [has no affect on the client's presence state and only enters on behalf of the provided client_id](./spec/acceptance/realtime/presence_spec.rb#
|
492
|
-
* [enters a channel and sets the data based on the provided :data option](./spec/acceptance/realtime/presence_spec.rb#
|
564
|
+
* [has no affect on the client's presence state and only enters on behalf of the provided client_id](./spec/acceptance/realtime/presence_spec.rb#L759)
|
565
|
+
* [enters a channel and sets the data based on the provided :data option](./spec/acceptance/realtime/presence_spec.rb#L773)
|
493
566
|
* message #connection_id
|
494
|
-
* [matches the current client connection_id](./spec/acceptance/realtime/presence_spec.rb#
|
567
|
+
* [matches the current client connection_id](./spec/acceptance/realtime/presence_spec.rb#L792)
|
495
568
|
* it should behave like a public presence method
|
496
569
|
* [raise an exception if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#L44)
|
497
570
|
* [raise an exception if the channel is failed](./spec/acceptance/realtime/presence_spec.rb#L44)
|
498
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#
|
499
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#
|
500
|
-
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#
|
571
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#L157)
|
572
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#L164)
|
573
|
+
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#L174)
|
574
|
+
* with supported data payload content type
|
575
|
+
* JSON Object (Hash)
|
576
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/realtime/presence_spec.rb#L73)
|
577
|
+
* JSON Array
|
578
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L83)
|
579
|
+
* String
|
580
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L93)
|
581
|
+
* Binary
|
582
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L103)
|
583
|
+
* with unsupported data payload content type
|
584
|
+
* Integer
|
585
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L123)
|
586
|
+
* Float
|
587
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L132)
|
588
|
+
* Boolean
|
589
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L141)
|
590
|
+
* False
|
591
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L150)
|
501
592
|
* if connection fails before success
|
502
|
-
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#
|
593
|
+
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#L195)
|
503
594
|
* without necessary capabilities to enter on behalf of another client
|
504
|
-
* [calls the Deferrable errback on capabilities failure](./spec/acceptance/realtime/presence_spec.rb#
|
595
|
+
* [calls the Deferrable errback on capabilities failure](./spec/acceptance/realtime/presence_spec.rb#L814)
|
505
596
|
* #update_client
|
506
597
|
* multiple times on the same channel with different client_ids
|
507
|
-
* [updates the data attribute for the member when :data option provided](./spec/acceptance/realtime/presence_spec.rb#
|
508
|
-
* [updates the data attribute to null for the member when :data option is not provided (assumed null)](./spec/acceptance/realtime/presence_spec.rb#
|
509
|
-
* [enters if not already entered](./spec/acceptance/realtime/presence_spec.rb#
|
598
|
+
* [updates the data attribute for the member when :data option provided](./spec/acceptance/realtime/presence_spec.rb#L825)
|
599
|
+
* [updates the data attribute to null for the member when :data option is not provided (assumed null)](./spec/acceptance/realtime/presence_spec.rb#L849)
|
600
|
+
* [enters if not already entered](./spec/acceptance/realtime/presence_spec.rb#L861)
|
510
601
|
* it should behave like a public presence method
|
511
602
|
* [raise an exception if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#L44)
|
512
603
|
* [raise an exception if the channel is failed](./spec/acceptance/realtime/presence_spec.rb#L44)
|
513
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#
|
514
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#
|
515
|
-
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#
|
604
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#L157)
|
605
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#L164)
|
606
|
+
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#L174)
|
607
|
+
* with supported data payload content type
|
608
|
+
* JSON Object (Hash)
|
609
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/realtime/presence_spec.rb#L73)
|
610
|
+
* JSON Array
|
611
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L83)
|
612
|
+
* String
|
613
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L93)
|
614
|
+
* Binary
|
615
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L103)
|
616
|
+
* with unsupported data payload content type
|
617
|
+
* Integer
|
618
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L123)
|
619
|
+
* Float
|
620
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L132)
|
621
|
+
* Boolean
|
622
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L141)
|
623
|
+
* False
|
624
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L150)
|
516
625
|
* if connection fails before success
|
517
|
-
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#
|
626
|
+
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#L195)
|
518
627
|
* #leave_client
|
519
628
|
* leaves a channel
|
520
629
|
* multiple times on the same channel with different client_ids
|
521
|
-
* [emits the :leave event for each client_id](./spec/acceptance/realtime/presence_spec.rb#
|
522
|
-
* [succeeds if that client_id has not previously entered the channel](./spec/acceptance/realtime/presence_spec.rb#
|
630
|
+
* [emits the :leave event for each client_id](./spec/acceptance/realtime/presence_spec.rb#L890)
|
631
|
+
* [succeeds if that client_id has not previously entered the channel](./spec/acceptance/realtime/presence_spec.rb#L914)
|
523
632
|
* with a new value in :data option
|
524
|
-
* [emits the leave event with the new data value](./spec/acceptance/realtime/presence_spec.rb#
|
633
|
+
* [emits the leave event with the new data value](./spec/acceptance/realtime/presence_spec.rb#L938)
|
525
634
|
* with a nil value in :data option
|
526
|
-
* [emits the leave event with the previous value as a convenience](./spec/acceptance/realtime/presence_spec.rb#
|
635
|
+
* [emits the leave event with the previous value as a convenience](./spec/acceptance/realtime/presence_spec.rb#L951)
|
527
636
|
* with no :data option
|
528
|
-
* [emits the leave event with the previous value as a convenience](./spec/acceptance/realtime/presence_spec.rb#
|
637
|
+
* [emits the leave event with the previous value as a convenience](./spec/acceptance/realtime/presence_spec.rb#L964)
|
529
638
|
* it should behave like a public presence method
|
530
639
|
* [raise an exception if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#L44)
|
531
640
|
* [raise an exception if the channel is failed](./spec/acceptance/realtime/presence_spec.rb#L44)
|
532
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#
|
533
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#
|
534
|
-
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#
|
641
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#L157)
|
642
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#L164)
|
643
|
+
* [catches exceptions in the provided method block and logs them to the logger](./spec/acceptance/realtime/presence_spec.rb#L174)
|
644
|
+
* with supported data payload content type
|
645
|
+
* JSON Object (Hash)
|
646
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/realtime/presence_spec.rb#L73)
|
647
|
+
* JSON Array
|
648
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L83)
|
649
|
+
* String
|
650
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L93)
|
651
|
+
* Binary
|
652
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/realtime/presence_spec.rb#L103)
|
653
|
+
* with unsupported data payload content type
|
654
|
+
* Integer
|
655
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L123)
|
656
|
+
* Float
|
657
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L132)
|
658
|
+
* Boolean
|
659
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L141)
|
660
|
+
* False
|
661
|
+
* [raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/realtime/presence_spec.rb#L150)
|
535
662
|
* if connection fails before success
|
536
|
-
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#
|
663
|
+
* [calls the Deferrable errback if channel is detached](./spec/acceptance/realtime/presence_spec.rb#L195)
|
537
664
|
* #get
|
538
|
-
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#
|
539
|
-
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#
|
540
|
-
* [catches exceptions in the provided method block](./spec/acceptance/realtime/presence_spec.rb#
|
541
|
-
* [raise an exception if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#
|
542
|
-
* [raise an exception if the channel is failed](./spec/acceptance/realtime/presence_spec.rb#
|
543
|
-
* [returns the current members on the channel](./spec/acceptance/realtime/presence_spec.rb#
|
544
|
-
* [filters by connection_id option if provided](./spec/acceptance/realtime/presence_spec.rb#
|
545
|
-
* [filters by client_id option if provided](./spec/acceptance/realtime/presence_spec.rb#
|
546
|
-
* [does not wait for SYNC to complete if :wait_for_sync option is false](./spec/acceptance/realtime/presence_spec.rb#
|
665
|
+
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/presence_spec.rb#L982)
|
666
|
+
* [calls the Deferrable callback on success](./spec/acceptance/realtime/presence_spec.rb#L987)
|
667
|
+
* [catches exceptions in the provided method block](./spec/acceptance/realtime/presence_spec.rb#L994)
|
668
|
+
* [raise an exception if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#L1002)
|
669
|
+
* [raise an exception if the channel is failed](./spec/acceptance/realtime/presence_spec.rb#L1002)
|
670
|
+
* [returns the current members on the channel](./spec/acceptance/realtime/presence_spec.rb#L1079)
|
671
|
+
* [filters by connection_id option if provided](./spec/acceptance/realtime/presence_spec.rb#L1094)
|
672
|
+
* [filters by client_id option if provided](./spec/acceptance/realtime/presence_spec.rb#L1116)
|
673
|
+
* [does not wait for SYNC to complete if :wait_for_sync option is false](./spec/acceptance/realtime/presence_spec.rb#L1140)
|
547
674
|
* during a sync
|
548
|
-
*
|
549
|
-
|
675
|
+
* when :wait_for_sync is true
|
676
|
+
* [fails if the connection fails](./spec/acceptance/realtime/presence_spec.rb#L1033)
|
677
|
+
* [fails if the channel is detached](./spec/acceptance/realtime/presence_spec.rb#L1053)
|
550
678
|
* when a member enters and then leaves
|
551
|
-
* [has no members](./spec/acceptance/realtime/presence_spec.rb#
|
679
|
+
* [has no members](./spec/acceptance/realtime/presence_spec.rb#L1150)
|
552
680
|
* with lots of members on different clients
|
553
|
-
* [returns a complete list of members on all clients](./spec/acceptance/realtime/presence_spec.rb#
|
681
|
+
* [returns a complete list of members on all clients](./spec/acceptance/realtime/presence_spec.rb#L1167)
|
554
682
|
* #subscribe
|
555
683
|
* with no arguments
|
556
|
-
* [calls the callback for all presence events](./spec/acceptance/realtime/presence_spec.rb#
|
684
|
+
* [calls the callback for all presence events](./spec/acceptance/realtime/presence_spec.rb#L1203)
|
557
685
|
* #unsubscribe
|
558
686
|
* with no arguments
|
559
|
-
* [removes the callback for all presence events](./spec/acceptance/realtime/presence_spec.rb#
|
687
|
+
* [removes the callback for all presence events](./spec/acceptance/realtime/presence_spec.rb#L1225)
|
560
688
|
* REST #get
|
561
|
-
* [returns current members](./spec/acceptance/realtime/presence_spec.rb#
|
562
|
-
* [returns no members once left](./spec/acceptance/realtime/presence_spec.rb#
|
689
|
+
* [returns current members](./spec/acceptance/realtime/presence_spec.rb#L1244)
|
690
|
+
* [returns no members once left](./spec/acceptance/realtime/presence_spec.rb#L1257)
|
563
691
|
* client_id with ASCII_8BIT
|
564
692
|
* in connection set up
|
565
|
-
* [is converted into UTF_8](./spec/acceptance/realtime/presence_spec.rb#
|
693
|
+
* [is converted into UTF_8](./spec/acceptance/realtime/presence_spec.rb#L1274)
|
566
694
|
* in channel options
|
567
|
-
* [is converted into UTF_8](./spec/acceptance/realtime/presence_spec.rb#
|
695
|
+
* [is converted into UTF_8](./spec/acceptance/realtime/presence_spec.rb#L1287)
|
568
696
|
* encoding and decoding of presence message data
|
569
|
-
* [encrypts presence message data](./spec/acceptance/realtime/presence_spec.rb#
|
697
|
+
* [encrypts presence message data](./spec/acceptance/realtime/presence_spec.rb#L1311)
|
570
698
|
* #subscribe
|
571
|
-
* [emits decrypted enter events](./spec/acceptance/realtime/presence_spec.rb#
|
572
|
-
* [emits decrypted update events](./spec/acceptance/realtime/presence_spec.rb#
|
573
|
-
* [emits previously set data for leave events](./spec/acceptance/realtime/presence_spec.rb#
|
699
|
+
* [emits decrypted enter events](./spec/acceptance/realtime/presence_spec.rb#L1330)
|
700
|
+
* [emits decrypted update events](./spec/acceptance/realtime/presence_spec.rb#L1342)
|
701
|
+
* [emits previously set data for leave events](./spec/acceptance/realtime/presence_spec.rb#L1356)
|
574
702
|
* #get
|
575
|
-
* [returns a list of members with decrypted data](./spec/acceptance/realtime/presence_spec.rb#
|
703
|
+
* [returns a list of members with decrypted data](./spec/acceptance/realtime/presence_spec.rb#L1372)
|
576
704
|
* REST #get
|
577
|
-
* [returns a list of members with decrypted data](./spec/acceptance/realtime/presence_spec.rb#
|
705
|
+
* [returns a list of members with decrypted data](./spec/acceptance/realtime/presence_spec.rb#L1385)
|
578
706
|
* when cipher settings do not match publisher
|
579
|
-
* [delivers an unencoded presence message left with encoding value](./spec/acceptance/realtime/presence_spec.rb#
|
580
|
-
* [emits an error when cipher does not match and presence data cannot be decoded](./spec/acceptance/realtime/presence_spec.rb#
|
707
|
+
* [delivers an unencoded presence message left with encoding value](./spec/acceptance/realtime/presence_spec.rb#L1400)
|
708
|
+
* [emits an error when cipher does not match and presence data cannot be decoded](./spec/acceptance/realtime/presence_spec.rb#L1413)
|
581
709
|
* leaving
|
582
|
-
* [expect :left event once underlying connection is closed](./spec/acceptance/realtime/presence_spec.rb#
|
583
|
-
* [expect :left event with client data from enter event](./spec/acceptance/realtime/presence_spec.rb#
|
710
|
+
* [expect :left event once underlying connection is closed](./spec/acceptance/realtime/presence_spec.rb#L1430)
|
711
|
+
* [expect :left event with client data from enter event](./spec/acceptance/realtime/presence_spec.rb#L1440)
|
584
712
|
* connection failure mid-way through a large member sync
|
585
|
-
*
|
713
|
+
* [resumes the SYNC operation](./spec/acceptance/realtime/presence_spec.rb#L1458)
|
586
714
|
|
587
715
|
### Ably::Realtime::Client#stats
|
588
716
|
_(see [spec/acceptance/realtime/stats_spec.rb](./spec/acceptance/realtime/stats_spec.rb))_
|
589
717
|
* using JSON and MsgPack protocol
|
590
718
|
* fetching stats
|
591
|
-
* [should return a
|
719
|
+
* [should return a PaginatedResult](./spec/acceptance/realtime/stats_spec.rb#L10)
|
592
720
|
* [returns a SafeDeferrable that catches exceptions in callbacks and logs them](./spec/acceptance/realtime/stats_spec.rb#L17)
|
593
721
|
|
594
722
|
### Ably::Realtime::Client#time
|
@@ -605,116 +733,116 @@ _(see [spec/acceptance/rest/auth_spec.rb](./spec/acceptance/rest/auth_spec.rb))_
|
|
605
733
|
* #request_token
|
606
734
|
* [returns a valid requested token in the expected format with valid issued and expires attributes](./spec/acceptance/rest/auth_spec.rb#L69)
|
607
735
|
* with option :client_id
|
608
|
-
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#
|
736
|
+
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#L101)
|
609
737
|
* with option :capability
|
610
|
-
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#
|
738
|
+
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#L101)
|
611
739
|
* with option :nonce
|
612
|
-
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#
|
740
|
+
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#L101)
|
613
741
|
* with option :timestamp
|
614
|
-
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#
|
742
|
+
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#L101)
|
615
743
|
* with option :ttl
|
616
|
-
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#
|
744
|
+
* [overrides default and uses camelCase notation for attributes](./spec/acceptance/rest/auth_spec.rb#L101)
|
617
745
|
* with :key option
|
618
|
-
* [key_name is used in request and signing uses key_secret](./spec/acceptance/rest/auth_spec.rb#
|
746
|
+
* [key_name is used in request and signing uses key_secret](./spec/acceptance/rest/auth_spec.rb#L130)
|
619
747
|
* with :key_name & :key_secret options
|
620
|
-
* [key_name is used in request and signing uses key_secret](./spec/acceptance/rest/auth_spec.rb#
|
748
|
+
* [key_name is used in request and signing uses key_secret](./spec/acceptance/rest/auth_spec.rb#L159)
|
621
749
|
* with :query_time option
|
622
|
-
* [queries the server for the time](./spec/acceptance/rest/auth_spec.rb#
|
750
|
+
* [queries the server for the time](./spec/acceptance/rest/auth_spec.rb#L167)
|
623
751
|
* without :query_time option
|
624
|
-
* [does not query the server for the time](./spec/acceptance/rest/auth_spec.rb#
|
752
|
+
* [does not query the server for the time](./spec/acceptance/rest/auth_spec.rb#L176)
|
625
753
|
* with :auth_url option
|
626
754
|
* when response from :auth_url is a valid token request
|
627
|
-
* [requests a token from :auth_url using an HTTP GET request](./spec/acceptance/rest/auth_spec.rb#
|
628
|
-
* [returns a valid token generated from the token request](./spec/acceptance/rest/auth_spec.rb#
|
755
|
+
* [requests a token from :auth_url using an HTTP GET request](./spec/acceptance/rest/auth_spec.rb#L224)
|
756
|
+
* [returns a valid token generated from the token request](./spec/acceptance/rest/auth_spec.rb#L229)
|
629
757
|
* with :query_params
|
630
|
-
* [requests a token from :auth_url with the :query_params](./spec/acceptance/rest/auth_spec.rb#
|
758
|
+
* [requests a token from :auth_url with the :query_params](./spec/acceptance/rest/auth_spec.rb#L236)
|
631
759
|
* with :headers
|
632
|
-
* [requests a token from :auth_url with the HTTP headers set](./spec/acceptance/rest/auth_spec.rb#
|
760
|
+
* [requests a token from :auth_url with the HTTP headers set](./spec/acceptance/rest/auth_spec.rb#L244)
|
633
761
|
* with POST
|
634
|
-
* [requests a token from :auth_url using an HTTP POST instead of the default GET](./spec/acceptance/rest/auth_spec.rb#
|
762
|
+
* [requests a token from :auth_url using an HTTP POST instead of the default GET](./spec/acceptance/rest/auth_spec.rb#L252)
|
635
763
|
* when response from :auth_url is a token details object
|
636
|
-
* [returns TokenDetails created from the token JSON](./spec/acceptance/rest/auth_spec.rb#
|
764
|
+
* [returns TokenDetails created from the token JSON](./spec/acceptance/rest/auth_spec.rb#L277)
|
637
765
|
* when response from :auth_url is text/plain content type and a token string
|
638
|
-
* [returns TokenDetails created from the token JSON](./spec/acceptance/rest/auth_spec.rb#
|
766
|
+
* [returns TokenDetails created from the token JSON](./spec/acceptance/rest/auth_spec.rb#L294)
|
639
767
|
* when response is invalid
|
640
768
|
* 500
|
641
|
-
* [raises ServerError](./spec/acceptance/rest/auth_spec.rb#
|
769
|
+
* [raises ServerError](./spec/acceptance/rest/auth_spec.rb#L307)
|
642
770
|
* XML
|
643
|
-
* [raises InvalidResponseBody](./spec/acceptance/rest/auth_spec.rb#
|
771
|
+
* [raises InvalidResponseBody](./spec/acceptance/rest/auth_spec.rb#L318)
|
644
772
|
* with a Proc for the :auth_callback option
|
645
773
|
* that returns a TokenRequest
|
646
|
-
* [calls the Proc when authenticating to obtain the request token](./spec/acceptance/rest/auth_spec.rb#
|
647
|
-
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#
|
774
|
+
* [calls the Proc when authenticating to obtain the request token](./spec/acceptance/rest/auth_spec.rb#L337)
|
775
|
+
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#L342)
|
648
776
|
* that returns a TokenDetails JSON object
|
649
|
-
* [calls the Proc when authenticating to obtain the request token](./spec/acceptance/rest/auth_spec.rb#
|
650
|
-
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#
|
777
|
+
* [calls the Proc when authenticating to obtain the request token](./spec/acceptance/rest/auth_spec.rb#L371)
|
778
|
+
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#L376)
|
651
779
|
* that returns a TokenDetails object
|
652
|
-
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#
|
780
|
+
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#L397)
|
653
781
|
* that returns a Token string
|
654
|
-
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#
|
782
|
+
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#L413)
|
655
783
|
* with client_id
|
656
|
-
* [returns a token with the client_id](./spec/acceptance/rest/auth_spec.rb#
|
784
|
+
* [returns a token with the client_id](./spec/acceptance/rest/auth_spec.rb#L445)
|
657
785
|
* before #authorise has been called
|
658
|
-
* [has no current_token_details](./spec/acceptance/rest/auth_spec.rb#
|
786
|
+
* [has no current_token_details](./spec/acceptance/rest/auth_spec.rb#L452)
|
659
787
|
* #authorise
|
660
|
-
* [updates the persisted auth options that are then used for subsequent authorise requests](./spec/acceptance/rest/auth_spec.rb#
|
788
|
+
* [updates the persisted auth options that are then used for subsequent authorise requests](./spec/acceptance/rest/auth_spec.rb#L499)
|
661
789
|
* when called for the first time since the client has been instantiated
|
662
|
-
* [passes all options to #request_token](./spec/acceptance/rest/auth_spec.rb#
|
663
|
-
* [returns a valid token](./spec/acceptance/rest/auth_spec.rb#
|
664
|
-
* [issues a new token if option :force => true](./spec/acceptance/rest/auth_spec.rb#
|
790
|
+
* [passes all options to #request_token](./spec/acceptance/rest/auth_spec.rb#L463)
|
791
|
+
* [returns a valid token](./spec/acceptance/rest/auth_spec.rb#L468)
|
792
|
+
* [issues a new token if option :force => true](./spec/acceptance/rest/auth_spec.rb#L472)
|
665
793
|
* with previous authorisation
|
666
|
-
* [does not request a token if current_token_details has not expired](./spec/acceptance/rest/auth_spec.rb#
|
667
|
-
* [requests a new token if token is expired](./spec/acceptance/rest/auth_spec.rb#
|
668
|
-
* [issues a new token if option :force => true](./spec/acceptance/rest/auth_spec.rb#
|
794
|
+
* [does not request a token if current_token_details has not expired](./spec/acceptance/rest/auth_spec.rb#L483)
|
795
|
+
* [requests a new token if token is expired](./spec/acceptance/rest/auth_spec.rb#L488)
|
796
|
+
* [issues a new token if option :force => true](./spec/acceptance/rest/auth_spec.rb#L494)
|
669
797
|
* with a Proc for the :auth_callback option
|
670
|
-
* [calls the Proc](./spec/acceptance/rest/auth_spec.rb#
|
671
|
-
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#
|
798
|
+
* [calls the Proc](./spec/acceptance/rest/auth_spec.rb#L515)
|
799
|
+
* [uses the token request returned from the callback when requesting a new token](./spec/acceptance/rest/auth_spec.rb#L519)
|
672
800
|
* for every subsequent #request_token
|
673
801
|
* without a :auth_callback Proc
|
674
|
-
* [calls the originally provided block](./spec/acceptance/rest/auth_spec.rb#
|
802
|
+
* [calls the originally provided block](./spec/acceptance/rest/auth_spec.rb#L525)
|
675
803
|
* with a provided block
|
676
|
-
* [does not call the originally provided Proc and calls the new #request_token :auth_callback Proc](./spec/acceptance/rest/auth_spec.rb#
|
804
|
+
* [does not call the originally provided Proc and calls the new #request_token :auth_callback Proc](./spec/acceptance/rest/auth_spec.rb#L532)
|
677
805
|
* #create_token_request
|
678
|
-
* [uses the key name from the client](./spec/acceptance/rest/auth_spec.rb#
|
679
|
-
* [uses the default TTL](./spec/acceptance/rest/auth_spec.rb#
|
680
|
-
* [uses the default capability](./spec/acceptance/rest/auth_spec.rb#
|
806
|
+
* [uses the key name from the client](./spec/acceptance/rest/auth_spec.rb#L548)
|
807
|
+
* [uses the default TTL](./spec/acceptance/rest/auth_spec.rb#L552)
|
808
|
+
* [uses the default capability](./spec/acceptance/rest/auth_spec.rb#L556)
|
681
809
|
* the nonce
|
682
|
-
* [is unique for every request](./spec/acceptance/rest/auth_spec.rb#
|
683
|
-
* [is at least 16 characters](./spec/acceptance/rest/auth_spec.rb#
|
810
|
+
* [is unique for every request](./spec/acceptance/rest/auth_spec.rb#L561)
|
811
|
+
* [is at least 16 characters](./spec/acceptance/rest/auth_spec.rb#L566)
|
684
812
|
* with option :ttl
|
685
|
-
* [overrides default](./spec/acceptance/rest/auth_spec.rb#
|
813
|
+
* [overrides default](./spec/acceptance/rest/auth_spec.rb#L577)
|
686
814
|
* with option :nonce
|
687
|
-
* [overrides default](./spec/acceptance/rest/auth_spec.rb#
|
815
|
+
* [overrides default](./spec/acceptance/rest/auth_spec.rb#L577)
|
688
816
|
* with option :client_id
|
689
|
-
* [overrides default](./spec/acceptance/rest/auth_spec.rb#
|
817
|
+
* [overrides default](./spec/acceptance/rest/auth_spec.rb#L577)
|
690
818
|
* with additional invalid attributes
|
691
|
-
* [are ignored](./spec/acceptance/rest/auth_spec.rb#
|
819
|
+
* [are ignored](./spec/acceptance/rest/auth_spec.rb#L585)
|
692
820
|
* when required fields are missing
|
693
|
-
* [should raise an exception if key secret is missing](./spec/acceptance/rest/auth_spec.rb#
|
694
|
-
* [should raise an exception if key name is missing](./spec/acceptance/rest/auth_spec.rb#
|
821
|
+
* [should raise an exception if key secret is missing](./spec/acceptance/rest/auth_spec.rb#L596)
|
822
|
+
* [should raise an exception if key name is missing](./spec/acceptance/rest/auth_spec.rb#L600)
|
695
823
|
* with :query_time option
|
696
|
-
* [queries the server for the timestamp](./spec/acceptance/rest/auth_spec.rb#
|
824
|
+
* [queries the server for the timestamp](./spec/acceptance/rest/auth_spec.rb#L609)
|
697
825
|
* with :timestamp option
|
698
|
-
* [uses the provided timestamp in the token request](./spec/acceptance/rest/auth_spec.rb#
|
826
|
+
* [uses the provided timestamp in the token request](./spec/acceptance/rest/auth_spec.rb#L619)
|
699
827
|
* signing
|
700
|
-
* [generates a valid HMAC](./spec/acceptance/rest/auth_spec.rb#
|
828
|
+
* [generates a valid HMAC](./spec/acceptance/rest/auth_spec.rb#L641)
|
701
829
|
* using token authentication
|
702
830
|
* with :token option
|
703
|
-
* [authenticates successfully using the provided :token](./spec/acceptance/rest/auth_spec.rb#
|
704
|
-
* [disallows publishing on unspecified capability channels](./spec/acceptance/rest/auth_spec.rb#
|
705
|
-
* [fails if timestamp is invalid](./spec/acceptance/rest/auth_spec.rb#
|
706
|
-
* [cannot be renewed automatically](./spec/acceptance/rest/auth_spec.rb#
|
831
|
+
* [authenticates successfully using the provided :token](./spec/acceptance/rest/auth_spec.rb#L664)
|
832
|
+
* [disallows publishing on unspecified capability channels](./spec/acceptance/rest/auth_spec.rb#L668)
|
833
|
+
* [fails if timestamp is invalid](./spec/acceptance/rest/auth_spec.rb#L676)
|
834
|
+
* [cannot be renewed automatically](./spec/acceptance/rest/auth_spec.rb#L684)
|
707
835
|
* when implicit as a result of using :client id
|
708
836
|
* and requests to the Ably server are mocked
|
709
|
-
* [will send a token request to the server](./spec/acceptance/rest/auth_spec.rb#
|
837
|
+
* [will send a token request to the server](./spec/acceptance/rest/auth_spec.rb#L712)
|
710
838
|
* a token is created
|
711
|
-
* [before a request is made](./spec/acceptance/rest/auth_spec.rb#
|
712
|
-
* [when a message is published](./spec/acceptance/rest/auth_spec.rb#
|
713
|
-
* [with capability and TTL defaults](./spec/acceptance/rest/auth_spec.rb#
|
839
|
+
* [before a request is made](./spec/acceptance/rest/auth_spec.rb#L721)
|
840
|
+
* [when a message is published](./spec/acceptance/rest/auth_spec.rb#L725)
|
841
|
+
* [with capability and TTL defaults](./spec/acceptance/rest/auth_spec.rb#L729)
|
714
842
|
* when using an :key and basic auth
|
715
|
-
* [#using_token_auth? is false](./spec/acceptance/rest/auth_spec.rb#
|
716
|
-
* [#key attribute contains the key string](./spec/acceptance/rest/auth_spec.rb#
|
717
|
-
* [#using_basic_auth? is true](./spec/acceptance/rest/auth_spec.rb#
|
843
|
+
* [#using_token_auth? is false](./spec/acceptance/rest/auth_spec.rb#L744)
|
844
|
+
* [#key attribute contains the key string](./spec/acceptance/rest/auth_spec.rb#L748)
|
845
|
+
* [#using_basic_auth? is true](./spec/acceptance/rest/auth_spec.rb#L752)
|
718
846
|
|
719
847
|
### Ably::Rest
|
720
848
|
_(see [spec/acceptance/rest/base_spec.rb](./spec/acceptance/rest/base_spec.rb))_
|
@@ -747,10 +875,10 @@ _(see [spec/acceptance/rest/base_spec.rb](./spec/acceptance/rest/base_spec.rb))_
|
|
747
875
|
_(see [spec/acceptance/rest/channel_spec.rb](./spec/acceptance/rest/channel_spec.rb))_
|
748
876
|
* using JSON and MsgPack protocol
|
749
877
|
* #publish
|
750
|
-
* [should publish the message and return true indicating success](./spec/acceptance/rest/channel_spec.rb#L17)
|
878
|
+
* FAILED: ~~[should publish the message and return true indicating success](./spec/acceptance/rest/channel_spec.rb#L17)~~
|
751
879
|
* #history
|
752
880
|
* [should return the current message history for the channel](./spec/acceptance/rest/channel_spec.rb#L39)
|
753
|
-
* [should return paged history using the
|
881
|
+
* [should return paged history using the PaginatedResult model](./spec/acceptance/rest/channel_spec.rb#L67)
|
754
882
|
* message timestamps
|
755
883
|
* [should all be after the messages were published](./spec/acceptance/rest/channel_spec.rb#L52)
|
756
884
|
* message IDs
|
@@ -854,7 +982,7 @@ _(see [spec/acceptance/rest/encoders_spec.rb](./spec/acceptance/rest/encoders_sp
|
|
854
982
|
* with UTF-8 data
|
855
983
|
* [applies utf-8, cipher and base64 encodings and sets the encoding attribute to "utf-8/cipher+aes-128-cbc/base64"](./spec/acceptance/rest/encoders_spec.rb#L154)
|
856
984
|
* with binary data
|
857
|
-
* [applies cipher and base64 encoding and sets the encoding attribute to "
|
985
|
+
* [applies cipher and base64 encoding and sets the encoding attribute to "cipher+aes-128-cbc/base64"](./spec/acceptance/rest/encoders_spec.rb#L165)
|
858
986
|
* with JSON data
|
859
987
|
* [applies json, utf-8, cipher and base64 encoding and sets the encoding attribute to "json/utf-8/cipher+aes-128-cbc/base64"](./spec/acceptance/rest/encoders_spec.rb#L176)
|
860
988
|
|
@@ -863,59 +991,77 @@ _(see [spec/acceptance/rest/message_spec.rb](./spec/acceptance/rest/message_spec
|
|
863
991
|
* using JSON and MsgPack protocol
|
864
992
|
* publishing with an ASCII_8BIT message name
|
865
993
|
* [is converted into UTF_8](./spec/acceptance/rest/message_spec.rb#L18)
|
994
|
+
* with supported data payload content type
|
995
|
+
* JSON Object (Hash)
|
996
|
+
* [is encoded and decoded to the same hash](./spec/acceptance/rest/message_spec.rb#L30)
|
997
|
+
* JSON Array
|
998
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/rest/message_spec.rb#L39)
|
999
|
+
* String
|
1000
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/rest/message_spec.rb#L48)
|
1001
|
+
* Binary
|
1002
|
+
* [is encoded and decoded to the same Array](./spec/acceptance/rest/message_spec.rb#L57)
|
1003
|
+
* with unsupported data payload content type
|
1004
|
+
* Integer
|
1005
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/rest/message_spec.rb#L68)
|
1006
|
+
* Float
|
1007
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/rest/message_spec.rb#L76)
|
1008
|
+
* Boolean
|
1009
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/rest/message_spec.rb#L84)
|
1010
|
+
* False
|
1011
|
+
* [is raises an UnsupportedDataTypeError 40011 exception](./spec/acceptance/rest/message_spec.rb#L92)
|
866
1012
|
* encryption and encoding
|
867
1013
|
* with #publish and #history
|
868
1014
|
* with AES-128-CBC using crypto-data-128.json fixtures
|
869
1015
|
* item 0 with encrypted encoding utf-8/cipher+aes-128-cbc/base64
|
870
1016
|
* behaves like an Ably encrypter and decrypter
|
871
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
872
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1017
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1018
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
873
1019
|
* item 1 with encrypted encoding cipher+aes-128-cbc/base64
|
874
1020
|
* behaves like an Ably encrypter and decrypter
|
875
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
876
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1021
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1022
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
877
1023
|
* item 2 with encrypted encoding json/utf-8/cipher+aes-128-cbc/base64
|
878
1024
|
* behaves like an Ably encrypter and decrypter
|
879
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
880
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1025
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1026
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
881
1027
|
* item 3 with encrypted encoding json/utf-8/cipher+aes-128-cbc/base64
|
882
1028
|
* behaves like an Ably encrypter and decrypter
|
883
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
884
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1029
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1030
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
885
1031
|
* with AES-256-CBC using crypto-data-256.json fixtures
|
886
1032
|
* item 0 with encrypted encoding utf-8/cipher+aes-256-cbc/base64
|
887
1033
|
* behaves like an Ably encrypter and decrypter
|
888
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
889
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1034
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1035
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
890
1036
|
* item 1 with encrypted encoding cipher+aes-256-cbc/base64
|
891
1037
|
* behaves like an Ably encrypter and decrypter
|
892
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
893
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1038
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1039
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
894
1040
|
* item 2 with encrypted encoding json/utf-8/cipher+aes-256-cbc/base64
|
895
1041
|
* behaves like an Ably encrypter and decrypter
|
896
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
897
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1042
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1043
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
898
1044
|
* item 3 with encrypted encoding json/utf-8/cipher+aes-256-cbc/base64
|
899
1045
|
* behaves like an Ably encrypter and decrypter
|
900
|
-
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#
|
901
|
-
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#
|
1046
|
+
* [encrypts message automatically when published](./spec/acceptance/rest/message_spec.rb#L137)
|
1047
|
+
* [sends and retrieves messages that are encrypted & decrypted by the Ably library](./spec/acceptance/rest/message_spec.rb#L152)
|
902
1048
|
* when publishing lots of messages
|
903
|
-
* [encrypts on #publish and decrypts on #history](./spec/acceptance/rest/message_spec.rb#
|
1049
|
+
* [encrypts on #publish and decrypts on #history](./spec/acceptance/rest/message_spec.rb#L185)
|
904
1050
|
* when retrieving #history with a different protocol
|
905
|
-
* [delivers a String ASCII-8BIT payload to the receiver](./spec/acceptance/rest/message_spec.rb#
|
906
|
-
* [delivers a String UTF-8 payload to the receiver](./spec/acceptance/rest/message_spec.rb#
|
907
|
-
* [delivers a Hash payload to the receiver](./spec/acceptance/rest/message_spec.rb#
|
1051
|
+
* [delivers a String ASCII-8BIT payload to the receiver](./spec/acceptance/rest/message_spec.rb#L212)
|
1052
|
+
* [delivers a String UTF-8 payload to the receiver](./spec/acceptance/rest/message_spec.rb#L212)
|
1053
|
+
* [delivers a Hash payload to the receiver](./spec/acceptance/rest/message_spec.rb#L212)
|
908
1054
|
* when publishing on an unencrypted channel and retrieving with #history on an encrypted channel
|
909
|
-
* [does not attempt to decrypt the message](./spec/acceptance/rest/message_spec.rb#
|
1055
|
+
* [does not attempt to decrypt the message](./spec/acceptance/rest/message_spec.rb#L228)
|
910
1056
|
* when publishing on an encrypted channel and retrieving with #history on an unencrypted channel
|
911
|
-
* [retrieves the message that remains encrypted with an encrypted encoding attribute](./spec/acceptance/rest/message_spec.rb#
|
912
|
-
* [logs a Cipher exception](./spec/acceptance/rest/message_spec.rb#
|
1057
|
+
* [retrieves the message that remains encrypted with an encrypted encoding attribute](./spec/acceptance/rest/message_spec.rb#L249)
|
1058
|
+
* [logs a Cipher exception](./spec/acceptance/rest/message_spec.rb#L255)
|
913
1059
|
* publishing on an encrypted channel and retrieving #history with a different algorithm on another client
|
914
|
-
* [retrieves the message that remains encrypted with an encrypted encoding attribute](./spec/acceptance/rest/message_spec.rb#
|
915
|
-
* [logs a Cipher exception](./spec/acceptance/rest/message_spec.rb#
|
1060
|
+
* [retrieves the message that remains encrypted with an encrypted encoding attribute](./spec/acceptance/rest/message_spec.rb#L276)
|
1061
|
+
* [logs a Cipher exception](./spec/acceptance/rest/message_spec.rb#L282)
|
916
1062
|
* publishing on an encrypted channel and subscribing with a different key on another client
|
917
|
-
* [retrieves the message that remains encrypted with an encrypted encoding attribute](./spec/acceptance/rest/message_spec.rb#
|
918
|
-
* [logs a Cipher exception](./spec/acceptance/rest/message_spec.rb#
|
1063
|
+
* [retrieves the message that remains encrypted with an encrypted encoding attribute](./spec/acceptance/rest/message_spec.rb#L303)
|
1064
|
+
* [logs a Cipher exception](./spec/acceptance/rest/message_spec.rb#L309)
|
919
1065
|
|
920
1066
|
### Ably::Rest::Presence
|
921
1067
|
_(see [spec/acceptance/rest/presence_spec.rb](./spec/acceptance/rest/presence_spec.rb))_
|
@@ -926,43 +1072,43 @@ _(see [spec/acceptance/rest/presence_spec.rb](./spec/acceptance/rest/presence_sp
|
|
926
1072
|
* with :limit option
|
927
1073
|
* [returns a paged response limiting number of members per page](./spec/acceptance/rest/presence_spec.rb#L55)
|
928
1074
|
* #history
|
929
|
-
* [returns recent presence activity](./spec/acceptance/rest/presence_spec.rb#
|
1075
|
+
* [returns recent presence activity](./spec/acceptance/rest/presence_spec.rb#L69)
|
930
1076
|
* with options
|
931
1077
|
* direction: :forwards
|
932
|
-
* [returns recent presence activity forwards with most recent history last](./spec/acceptance/rest/presence_spec.rb#
|
1078
|
+
* [returns recent presence activity forwards with most recent history last](./spec/acceptance/rest/presence_spec.rb#L85)
|
933
1079
|
* direction: :backwards
|
934
|
-
* [returns recent presence activity backwards with most recent history first](./spec/acceptance/rest/presence_spec.rb#
|
1080
|
+
* [returns recent presence activity backwards with most recent history first](./spec/acceptance/rest/presence_spec.rb#L100)
|
935
1081
|
* #history
|
936
1082
|
* with time range options
|
937
1083
|
* :start
|
938
1084
|
* with milliseconds since epoch value
|
939
|
-
* [uses this value in the history request](./spec/acceptance/rest/presence_spec.rb#
|
1085
|
+
* [uses this value in the history request](./spec/acceptance/rest/presence_spec.rb#L152)
|
940
1086
|
* with Time object value
|
941
|
-
* [converts the value to milliseconds since epoch in the hisotry request](./spec/acceptance/rest/presence_spec.rb#
|
1087
|
+
* [converts the value to milliseconds since epoch in the hisotry request](./spec/acceptance/rest/presence_spec.rb#L162)
|
942
1088
|
* :end
|
943
1089
|
* with milliseconds since epoch value
|
944
|
-
* [uses this value in the history request](./spec/acceptance/rest/presence_spec.rb#
|
1090
|
+
* [uses this value in the history request](./spec/acceptance/rest/presence_spec.rb#L152)
|
945
1091
|
* with Time object value
|
946
|
-
* [converts the value to milliseconds since epoch in the hisotry request](./spec/acceptance/rest/presence_spec.rb#
|
1092
|
+
* [converts the value to milliseconds since epoch in the hisotry request](./spec/acceptance/rest/presence_spec.rb#L162)
|
947
1093
|
* decoding
|
948
1094
|
* with encoded fixture data
|
949
1095
|
* #history
|
950
|
-
* [decodes encoded and encryped presence fixture data automatically](./spec/acceptance/rest/presence_spec.rb#
|
1096
|
+
* [decodes encoded and encryped presence fixture data automatically](./spec/acceptance/rest/presence_spec.rb#L182)
|
951
1097
|
* #get
|
952
|
-
* [decodes encoded and encryped presence fixture data automatically](./spec/acceptance/rest/presence_spec.rb#
|
1098
|
+
* [decodes encoded and encryped presence fixture data automatically](./spec/acceptance/rest/presence_spec.rb#L189)
|
953
1099
|
* decoding permutations using mocked #history
|
954
1100
|
* valid decodeable content
|
955
1101
|
* #get
|
956
|
-
* [automaticaly decodes presence messages](./spec/acceptance/rest/presence_spec.rb#
|
1102
|
+
* [automaticaly decodes presence messages](./spec/acceptance/rest/presence_spec.rb#L245)
|
957
1103
|
* #history
|
958
|
-
* [automaticaly decodes presence messages](./spec/acceptance/rest/presence_spec.rb#
|
1104
|
+
* [automaticaly decodes presence messages](./spec/acceptance/rest/presence_spec.rb#L262)
|
959
1105
|
* invalid data
|
960
1106
|
* #get
|
961
|
-
* [returns the messages still encoded](./spec/acceptance/rest/presence_spec.rb#
|
962
|
-
* [logs a cipher error](./spec/acceptance/rest/presence_spec.rb#
|
1107
|
+
* [returns the messages still encoded](./spec/acceptance/rest/presence_spec.rb#L293)
|
1108
|
+
* [logs a cipher error](./spec/acceptance/rest/presence_spec.rb#L297)
|
963
1109
|
* #history
|
964
|
-
* [returns the messages still encoded](./spec/acceptance/rest/presence_spec.rb#
|
965
|
-
* [logs a cipher error](./spec/acceptance/rest/presence_spec.rb#
|
1110
|
+
* [returns the messages still encoded](./spec/acceptance/rest/presence_spec.rb#L317)
|
1111
|
+
* [logs a cipher error](./spec/acceptance/rest/presence_spec.rb#L321)
|
966
1112
|
|
967
1113
|
### Ably::Rest::Client#stats
|
968
1114
|
_(see [spec/acceptance/rest/stats_spec.rb](./spec/acceptance/rest/stats_spec.rb))_
|
@@ -1276,41 +1422,41 @@ _(see [spec/unit/models/message_spec.rb](./spec/unit/models/message_spec.rb))_
|
|
1276
1422
|
* as Nil
|
1277
1423
|
* [is permitted](./spec/unit/models/message_spec.rb#L134)
|
1278
1424
|
|
1279
|
-
### Ably::Models::
|
1280
|
-
_(see [spec/unit/models/
|
1425
|
+
### Ably::Models::PaginatedResult
|
1426
|
+
_(see [spec/unit/models/paginated_result_spec.rb](./spec/unit/models/paginated_result_spec.rb))_
|
1281
1427
|
* #items
|
1282
|
-
* [returns correct length from body](./spec/unit/models/
|
1283
|
-
* [is Enumerable](./spec/unit/models/
|
1284
|
-
* [is iterable](./spec/unit/models/
|
1285
|
-
* [provides [] accessor method](./spec/unit/models/
|
1286
|
-
* [#first gets the first item in page](./spec/unit/models/
|
1287
|
-
* [#last gets the last item in page](./spec/unit/models/
|
1428
|
+
* [returns correct length from body](./spec/unit/models/paginated_result_spec.rb#L31)
|
1429
|
+
* [is Enumerable](./spec/unit/models/paginated_result_spec.rb#L35)
|
1430
|
+
* [is iterable](./spec/unit/models/paginated_result_spec.rb#L39)
|
1431
|
+
* [provides [] accessor method](./spec/unit/models/paginated_result_spec.rb#L57)
|
1432
|
+
* [#first gets the first item in page](./spec/unit/models/paginated_result_spec.rb#L63)
|
1433
|
+
* [#last gets the last item in page](./spec/unit/models/paginated_result_spec.rb#L67)
|
1288
1434
|
* #each
|
1289
|
-
* [returns an enumerator](./spec/unit/models/
|
1290
|
-
* [yields each item](./spec/unit/models/
|
1435
|
+
* [returns an enumerator](./spec/unit/models/paginated_result_spec.rb#L44)
|
1436
|
+
* [yields each item](./spec/unit/models/paginated_result_spec.rb#L48)
|
1291
1437
|
* with non paged http response
|
1292
|
-
* [is the first page](./spec/unit/models/
|
1293
|
-
* [is the last page](./spec/unit/models/
|
1294
|
-
* [does not have next page](./spec/unit/models/
|
1295
|
-
* [does not support pagination](./spec/unit/models/
|
1296
|
-
* [returns nil when accessing next page](./spec/unit/models/
|
1297
|
-
* [returns nil when accessing first page](./spec/unit/models/
|
1438
|
+
* [is the first page](./spec/unit/models/paginated_result_spec.rb#L172)
|
1439
|
+
* [is the last page](./spec/unit/models/paginated_result_spec.rb#L176)
|
1440
|
+
* [does not have next page](./spec/unit/models/paginated_result_spec.rb#L180)
|
1441
|
+
* [does not support pagination](./spec/unit/models/paginated_result_spec.rb#L184)
|
1442
|
+
* [returns nil when accessing next page](./spec/unit/models/paginated_result_spec.rb#L188)
|
1443
|
+
* [returns nil when accessing first page](./spec/unit/models/paginated_result_spec.rb#L192)
|
1298
1444
|
* with paged http response
|
1299
|
-
* [is the first page](./spec/unit/models/
|
1300
|
-
* [has next page](./spec/unit/models/
|
1301
|
-
* [is not the last page](./spec/unit/models/
|
1302
|
-
* [supports pagination](./spec/unit/models/
|
1445
|
+
* [is the first page](./spec/unit/models/paginated_result_spec.rb#L210)
|
1446
|
+
* [has next page](./spec/unit/models/paginated_result_spec.rb#L214)
|
1447
|
+
* [is not the last page](./spec/unit/models/paginated_result_spec.rb#L218)
|
1448
|
+
* [supports pagination](./spec/unit/models/paginated_result_spec.rb#L222)
|
1303
1449
|
* accessing next page
|
1304
|
-
* [returns another
|
1305
|
-
* [retrieves the next page of results](./spec/unit/models/
|
1306
|
-
* [is not the first page](./spec/unit/models/
|
1307
|
-
* [does not have a next page](./spec/unit/models/
|
1308
|
-
* [is the last page](./spec/unit/models/
|
1309
|
-
* [returns nil when trying to access the last page when it is the last page](./spec/unit/models/
|
1450
|
+
* [returns another PaginatedResult](./spec/unit/models/paginated_result_spec.rb#L250)
|
1451
|
+
* [retrieves the next page of results](./spec/unit/models/paginated_result_spec.rb#L254)
|
1452
|
+
* [is not the first page](./spec/unit/models/paginated_result_spec.rb#L259)
|
1453
|
+
* [does not have a next page](./spec/unit/models/paginated_result_spec.rb#L263)
|
1454
|
+
* [is the last page](./spec/unit/models/paginated_result_spec.rb#L267)
|
1455
|
+
* [returns nil when trying to access the last page when it is the last page](./spec/unit/models/paginated_result_spec.rb#L271)
|
1310
1456
|
* and then first page
|
1311
|
-
* [returns a
|
1312
|
-
* [retrieves the first page of results](./spec/unit/models/
|
1313
|
-
* [is the first page](./spec/unit/models/
|
1457
|
+
* [returns a PaginatedResult](./spec/unit/models/paginated_result_spec.rb#L282)
|
1458
|
+
* [retrieves the first page of results](./spec/unit/models/paginated_result_spec.rb#L286)
|
1459
|
+
* [is the first page](./spec/unit/models/paginated_result_spec.rb#L290)
|
1314
1460
|
|
1315
1461
|
### Ably::Models::PresenceMessage
|
1316
1462
|
_(see [spec/unit/models/presence_message_spec.rb](./spec/unit/models/presence_message_spec.rb))_
|
@@ -1679,7 +1825,7 @@ _(see [spec/unit/models/token_request_spec.rb](./spec/unit/models/token_request_
|
|
1679
1825
|
|
1680
1826
|
### Ably::Modules::EventEmitter
|
1681
1827
|
_(see [spec/unit/modules/event_emitter_spec.rb](./spec/unit/modules/event_emitter_spec.rb))_
|
1682
|
-
* #
|
1828
|
+
* #emit event fan out
|
1683
1829
|
* [should emit an event for any number of subscribers](./spec/unit/modules/event_emitter_spec.rb#L19)
|
1684
1830
|
* [sends only messages to matching event names](./spec/unit/modules/event_emitter_spec.rb#L28)
|
1685
1831
|
* #on subscribe to multiple events
|
@@ -1716,7 +1862,7 @@ _(see [spec/unit/modules/state_emitter_spec.rb](./spec/unit/modules/state_emitte
|
|
1716
1862
|
* [#state= sets current state](./spec/unit/modules/state_emitter_spec.rb#L32)
|
1717
1863
|
* [#change_state sets current state](./spec/unit/modules/state_emitter_spec.rb#L36)
|
1718
1864
|
* #change_state with arguments
|
1719
|
-
* [passes the arguments through to the
|
1865
|
+
* [passes the arguments through to the executed callback](./spec/unit/modules/state_emitter_spec.rb#L44)
|
1720
1866
|
* #state?
|
1721
1867
|
* [returns true if state matches](./spec/unit/modules/state_emitter_spec.rb#L55)
|
1722
1868
|
* [returns false if state does not match](./spec/unit/modules/state_emitter_spec.rb#L59)
|
@@ -2068,6 +2214,6 @@ _(see [spec/unit/util/pub_sub_spec.rb](./spec/unit/util/pub_sub_spec.rb))_
|
|
2068
2214
|
|
2069
2215
|
## Test summary
|
2070
2216
|
|
2071
|
-
* Passing tests:
|
2072
|
-
* Pending tests:
|
2217
|
+
* Passing tests: 1092
|
2218
|
+
* Pending tests: 6
|
2073
2219
|
* Failing tests: 0
|