flock_os 0.0.2 → 0.0.3
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 +4 -4
- data/lib/flock_os/api/channels.rb +1 -1
- data/lib/flock_os/version.rb +1 -1
- data/spec/collection/channel_member_spec.rb +38 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b4344db63440885fbd91ac908f218ccf10d380a8fb4027e73f13b4fe4676da6c
|
4
|
+
data.tar.gz: c7ab15fb63bd81c90bb96ce23c03a86b5941f0b595034ec4005206b7d6a8627f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d54e36365b3c0151fe0fdb432f5ad257d3acb7bc6eb88d48a008796d9e73f13e9954f857251f416378ba7725e843c744479f387251ac59d2d7df2f7a6e59c870
|
7
|
+
data.tar.gz: 031cd9a483e246cea0f005309b078cb908084475413b329c7953413e8c2e98d2f27548eee27e70f1d22c0dd9885177732fe4134165758b74ca4a35a84b6f49c5
|
data/lib/flock_os/version.rb
CHANGED
@@ -0,0 +1,38 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe FlockOs::Collection::ChannelMember do
|
4
|
+
let(:channel_members) do
|
5
|
+
(1..3).map do |n|
|
6
|
+
{
|
7
|
+
userId: "u:#{n}",
|
8
|
+
affiliation: "member",
|
9
|
+
publicProfile: {
|
10
|
+
id: "u:#{n}",
|
11
|
+
firstName: "Nicole #{n}",
|
12
|
+
lastName: "Sullivan",
|
13
|
+
profileImage: "https://i.flockusercontent.com/xxxxxx"
|
14
|
+
}
|
15
|
+
}
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
subject(:collection) { described_class.new(channel_members) }
|
20
|
+
|
21
|
+
describe '#initialize' do
|
22
|
+
it 'return described class' do
|
23
|
+
expect(collection).to be_an described_class
|
24
|
+
end
|
25
|
+
|
26
|
+
it 'collection is not empty' do
|
27
|
+
expect(collection.collection).to be_an Array
|
28
|
+
end
|
29
|
+
|
30
|
+
it 'first collection has correct attributes' do
|
31
|
+
first_collection = collection.collection.first
|
32
|
+
|
33
|
+
expect(first_collection.user_id).to eq 'u:1'
|
34
|
+
expect(first_collection.affiliation).to eq 'member'
|
35
|
+
expect(first_collection.public_profile).to be_an Hash
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: flock_os
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Risal Hidayat
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-10-
|
11
|
+
date: 2022-10-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -171,6 +171,7 @@ files:
|
|
171
171
|
- lib/flock_os/version.rb
|
172
172
|
- spec/api/channels_spec.rb
|
173
173
|
- spec/api/chat_spec.rb
|
174
|
+
- spec/collection/channel_member_spec.rb
|
174
175
|
- spec/flock_os_spec.rb
|
175
176
|
- spec/helpers_spec.rb
|
176
177
|
- spec/spec_helper.rb
|