buoy_data 1.0.0.beta.2 → 1.0.0.beta.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.
- data/VERSION +1 -1
- data/buoy_data.gemspec +2 -2
- data/lib/buoy_data/noaa_station.rb +2 -1
- data/spec/noaa_station_spec.rb +18 -2
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.0.beta.
|
1
|
+
1.0.0.beta.3
|
data/buoy_data.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{buoy_data}
|
8
|
-
s.version = "1.0.0.beta.
|
8
|
+
s.version = "1.0.0.beta.3"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Adam Weller"]
|
12
|
-
s.date = %q{2011-05-
|
12
|
+
s.date = %q{2011-05-12}
|
13
13
|
s.description = %q{The goal of this gem is to provide marine buoy data from a variety of sources}
|
14
14
|
s.email = %q{minch@trazzler.com}
|
15
15
|
s.extra_rdoc_files = [
|
data/spec/noaa_station_spec.rb
CHANGED
@@ -4,12 +4,28 @@ describe BuoyData::NoaaStation do
|
|
4
4
|
let (:station) { BuoyData::NoaaStation.new }
|
5
5
|
|
6
6
|
it "should scrape station" do
|
7
|
-
|
7
|
+
url = station_url
|
8
|
+
data = station.scrape url
|
8
9
|
data.should_not be_empty
|
9
10
|
data.should be_a(Hash)
|
10
11
|
|
11
12
|
data[:wtmp].should be_a(Float)
|
12
|
-
data[:source_updated_at]
|
13
|
+
source_updated_at = data[:source_updated_at]
|
14
|
+
source_updated_at.should be_a(Time)
|
15
|
+
source_updated_at.zone.should == 'UTC'
|
16
|
+
end
|
17
|
+
|
18
|
+
it "should scrape buoy" do
|
19
|
+
url = buoy_url
|
20
|
+
data = station.scrape url
|
21
|
+
data.should_not be_empty
|
22
|
+
data.should be_a(Hash)
|
23
|
+
|
24
|
+
data[:wtmp].should be_a(Float)
|
25
|
+
source_updated_at = data[:source_updated_at]
|
26
|
+
source_updated_at.should be_a(Time)
|
27
|
+
source_updated_at.zone.should == 'UTC'
|
28
|
+
p source_updated_at
|
13
29
|
end
|
14
30
|
|
15
31
|
def station_url
|
metadata
CHANGED
@@ -7,8 +7,8 @@ version: !ruby/object:Gem::Version
|
|
7
7
|
- 0
|
8
8
|
- 0
|
9
9
|
- beta
|
10
|
-
-
|
11
|
-
version: 1.0.0.beta.
|
10
|
+
- 3
|
11
|
+
version: 1.0.0.beta.3
|
12
12
|
platform: ruby
|
13
13
|
authors:
|
14
14
|
- Adam Weller
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2011-05-
|
19
|
+
date: 2011-05-12 00:00:00 -04:00
|
20
20
|
default_executable:
|
21
21
|
dependencies:
|
22
22
|
- !ruby/object:Gem::Dependency
|