facegroup 0.3.0 → 0.4.0
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/facegroup/attachment.rb +2 -1
- data/lib/facegroup/version.rb +1 -1
- data/spec/facegroup_spec.rb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e105c6bcff0efb38b4c6f5b58da760b5a966ad15
|
4
|
+
data.tar.gz: fc6d589da35551c10b33815271c39e6ceb2893d3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b6a9d75f4f149b8dbcb33a19f09074c4d6803eec776c7fd501fd54d29591aeefdbb192e35b8a987f701dbb826d464f194d5778155c0128e0328ebb6148fd8b70
|
7
|
+
data.tar.gz: 51cefad820bc85cfeb9967c8205c606df003c893766bf5ab4975d5ee89e6515cca2344dfa34efc9b95990249894557b1a40b01a25b437e271ae1d48b9c1b8f4d
|
data/lib/facegroup/attachment.rb
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
module FaceGroup
|
4
4
|
# Attached URL to Posting
|
5
5
|
class Attachment
|
6
|
-
attr_reader :title, :description, :url
|
6
|
+
attr_reader :title, :description, :url, :media_url
|
7
7
|
|
8
8
|
def initialize(data)
|
9
9
|
return unless data
|
@@ -11,6 +11,7 @@ module FaceGroup
|
|
11
11
|
@title = attachment_data['title']
|
12
12
|
@description = attachment_data['description']
|
13
13
|
@url = attachment_data['url']
|
14
|
+
@media_url = attachment_data&.[]('media')&.[]('image')&.[]('src')
|
14
15
|
end
|
15
16
|
end
|
16
17
|
end
|
data/lib/facegroup/version.rb
CHANGED
data/spec/facegroup_spec.rb
CHANGED
@@ -67,6 +67,7 @@ describe 'FaceGroup specifications' do
|
|
67
67
|
retrieved.attachment.wont_be_nil
|
68
68
|
retrieved.attachment.description.must_equal attachment['description']
|
69
69
|
retrieved.attachment.url.must_match 'tutorialzine'
|
70
|
+
retrieved.attachment.media_url.must_match 'https://'
|
70
71
|
end
|
71
72
|
|
72
73
|
it '(SAD) should return nil if Posting ID is invalid' do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: facegroup
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Soumya Ray
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-11-
|
11
|
+
date: 2016-11-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: http
|