ndbc 0.1.0 → 0.1.1
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/changelog.md +3 -0
- data/lib/ndbc.rb +2 -2
- data/lib/ndbc/version.rb +1 -1
- data/spec/fixtures/vcr_cassettes/continuous_winds_data.yml +6673 -0
- data/spec/fixtures/vcr_cassettes/continuous_winds_data_station_not_found.yml +44 -0
- data/spec/fixtures/vcr_cassettes/spectral_wave_forecasts.yml +334 -335
- data/spec/fixtures/vcr_cassettes/spectral_wave_forecasts_station_not_found.yml +2 -2
- data/spec/fixtures/vcr_cassettes/spectral_wave_summaries.yml +2301 -0
- data/spec/fixtures/vcr_cassettes/spectral_wave_summaries_station_not_found.yml +44 -0
- data/spec/fixtures/vcr_cassettes/standard_meteorological_data.yml +7801 -0
- data/spec/fixtures/vcr_cassettes/standard_meteorological_data_station_not_found.yml +44 -0
- data/spec/fixtures/vcr_cassettes/station_table.yml +4123 -1
- data/spec/ndbc/station_spec.rb +4 -4
- metadata +2 -2
data/spec/ndbc/station_spec.rb
CHANGED
|
@@ -2,7 +2,7 @@ require 'spec_helper'
|
|
|
2
2
|
|
|
3
3
|
describe NDBC::Station do
|
|
4
4
|
|
|
5
|
-
subject(:station) { NDBC::Station.new(
|
|
5
|
+
subject(:station) { NDBC::Station.new(42039) }
|
|
6
6
|
|
|
7
7
|
let(:not_found_station) { NDBC::Station.new('00000') }
|
|
8
8
|
|
|
@@ -16,7 +16,7 @@ describe NDBC::Station do
|
|
|
16
16
|
describe "initialization" do
|
|
17
17
|
|
|
18
18
|
it "assigns the id" do
|
|
19
|
-
expect(station.id).to eq("
|
|
19
|
+
expect(station.id).to eq("42039")
|
|
20
20
|
end
|
|
21
21
|
|
|
22
22
|
it "has a connection" do
|
|
@@ -90,7 +90,7 @@ describe NDBC::Station do
|
|
|
90
90
|
end
|
|
91
91
|
|
|
92
92
|
it "skips the first two rows of raw data" do
|
|
93
|
-
expect(result[:values].first["YY"]).to
|
|
93
|
+
expect(result[:values].first["YY"]).to match(/^\d{4}$/)
|
|
94
94
|
end
|
|
95
95
|
end
|
|
96
96
|
|
|
@@ -139,7 +139,7 @@ describe NDBC::Station do
|
|
|
139
139
|
end
|
|
140
140
|
|
|
141
141
|
it "parses the cycle line and uses it to set up the first date" do
|
|
142
|
-
expect(response.first[:time]).to
|
|
142
|
+
expect(response.first[:time]).to be_a DateTime
|
|
143
143
|
end
|
|
144
144
|
|
|
145
145
|
it "returns an array of hashes with a height key" do
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ndbc
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ryan Hertz
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2018-06-30 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|