nasa_apod 1.0.3 → 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/nasa_apod/client.rb +0 -1
- data/lib/nasa_apod/search_results.rb +2 -1
- data/lib/nasa_apod/version.rb +1 -1
- data/spec/nasa_apod_spec.rb +5 -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: 6b58e0774136c271bb04189fc74ba690eda54a07
|
4
|
+
data.tar.gz: 6ceb8c4d189a9138d0f6e6dbd142484227c743a6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1fe2d863ca222cf546afff323901452673c1b7b7db485b0f8195ea9da8e86633c0ab0a46a8d589e878b1421ae6ea6f26a6842ded7e5c6aa8210a254cbe0dbc3c
|
7
|
+
data.tar.gz: c72daf331f6868705d1b189092fd62e03cae682cc30b1b2b99dbdc622e1b409207af770847065809366d85761a8378fddf5d93e37bbac3800d11226104dc18fb
|
data/lib/nasa_apod/client.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
module NasaApod
|
2
2
|
|
3
3
|
class SearchResults
|
4
|
-
attr_accessor :concepts, :url, :media_type, :title, :explanation, :hd_url, :date
|
4
|
+
attr_accessor :concepts, :url, :media_type, :title, :explanation, :hd_url, :date, :copyright
|
5
5
|
|
6
6
|
def initialize(attributes={})
|
7
7
|
@concepts = attributes["concepts"]
|
@@ -11,6 +11,7 @@ module NasaApod
|
|
11
11
|
@title = attributes["title"]
|
12
12
|
@hd_url = attributes["hdurl"]
|
13
13
|
@date = attributes["date"]
|
14
|
+
@copyright = attributes["copyright"]
|
14
15
|
end
|
15
16
|
end
|
16
17
|
|
data/lib/nasa_apod/version.rb
CHANGED
data/spec/nasa_apod_spec.rb
CHANGED
@@ -32,6 +32,11 @@ module NasaApod
|
|
32
32
|
expect(results.date).to eq(Date.today.prev_day.to_s)
|
33
33
|
end
|
34
34
|
|
35
|
+
it 'returns copyright' do
|
36
|
+
results = client.search(:date => Date.today.prev_day)
|
37
|
+
expect(results.copyright).to_not be(nil)
|
38
|
+
end
|
39
|
+
|
35
40
|
it 'changes picture when date changes' do
|
36
41
|
results = client.search(:date => Date.today.prev_day)
|
37
42
|
yesterdays_title = results.title
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nasa_apod
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabe Dominguez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-04-
|
11
|
+
date: 2016-04-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|