sac_county_data 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +2 -0
- data/README.md +16 -0
- data/lib/sac_county_data.rb +4 -0
- data/lib/sac_county_data/building_permits.rb +41 -0
- data/lib/sac_county_data/county_contracts.rb +30 -0
- data/lib/sac_county_data/outstanding_checks.rb +1 -1
- data/lib/sac_county_data/process_servers.rb +28 -0
- data/lib/sac_county_data/restaurant_inspections.rb +33 -0
- data/lib/sac_county_data/version.rb +1 -1
- data/sac_county_data.gemspec +3 -1
- data/test/building_permits_test.rb +22 -0
- data/test/county_contracts_test.rb +22 -0
- data/test/fixtures/vcr_cassettes/building_permits.yml +51141 -0
- data/test/fixtures/vcr_cassettes/county_contracts.yml +8906 -0
- data/test/fixtures/vcr_cassettes/outstanding_checks.yml +7509 -0
- data/test/fixtures/vcr_cassettes/process_servers.yml +464 -0
- data/test/fixtures/vcr_cassettes/restaurant_inspections.yml +22557 -0
- data/test/outstanding_checks_test.rb +6 -3
- data/test/process_servers_test.rb +22 -0
- data/test/restaurant_inspections_test.rb +22 -0
- data/test/test_helper.rb +7 -0
- metadata +53 -4
- data/lib/sac_county_data/.outstanding_checks.rb.swp +0 -0
@@ -12,8 +12,11 @@ describe 'SacCountyData::OutstandingChecks' do
|
|
12
12
|
end
|
13
13
|
|
14
14
|
it 'should return all outstanding checks' do
|
15
|
-
|
16
|
-
|
17
|
-
|
15
|
+
VCR.use_cassette 'outstanding_checks' do
|
16
|
+
checks = SacCountyData::OutstandingChecks.all
|
17
|
+
|
18
|
+
assert checks.is_a? Array
|
19
|
+
assert checks.length == 7017
|
20
|
+
end
|
18
21
|
end
|
19
22
|
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
require './test/test_helper'
|
2
|
+
|
3
|
+
describe 'SacCountyData::ProcessServers' do
|
4
|
+
before do
|
5
|
+
SacCountyData.configure do |config|
|
6
|
+
config.api_key = ''
|
7
|
+
end
|
8
|
+
end
|
9
|
+
|
10
|
+
it 'should exist for sure' do
|
11
|
+
assert SacCountyData::ProcessServers
|
12
|
+
end
|
13
|
+
|
14
|
+
it 'should return all process servers' do
|
15
|
+
VCR.use_cassette 'process_servers' do
|
16
|
+
servers = SacCountyData::ProcessServers.all
|
17
|
+
|
18
|
+
assert servers.is_a? Array
|
19
|
+
assert servers.length == 208
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
require './test/test_helper'
|
2
|
+
|
3
|
+
describe SacCountyData::RestaurantInspections do
|
4
|
+
before do
|
5
|
+
SacCountyData.configure do |config|
|
6
|
+
config.api_key = ''
|
7
|
+
end
|
8
|
+
end
|
9
|
+
|
10
|
+
it 'should exist for sure' do
|
11
|
+
assert SacCountyData::RestaurantInspections
|
12
|
+
end
|
13
|
+
|
14
|
+
it 'should return all restaurant inspections' do
|
15
|
+
VCR.use_cassette 'restaurant_inspections' do
|
16
|
+
inspections = SacCountyData::RestaurantInspections.all
|
17
|
+
|
18
|
+
assert inspections.is_a? Array
|
19
|
+
assert inspections.length == 5577, inspections.length
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
data/test/test_helper.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sac_county_data
|
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
|
- Chris Cacciatore
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -66,6 +66,34 @@ dependencies:
|
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '5.8'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: vcr
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '2.9'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '2.9'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: webmock
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '1.21'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '1.21'
|
69
97
|
- !ruby/object:Gem::Dependency
|
70
98
|
name: faraday
|
71
99
|
requirement: !ruby/object:Gem::Requirement
|
@@ -107,13 +135,25 @@ files:
|
|
107
135
|
- README.md
|
108
136
|
- Rakefile
|
109
137
|
- lib/sac_county_data.rb
|
110
|
-
- lib/sac_county_data
|
138
|
+
- lib/sac_county_data/building_permits.rb
|
139
|
+
- lib/sac_county_data/county_contracts.rb
|
111
140
|
- lib/sac_county_data/outstanding_checks.rb
|
141
|
+
- lib/sac_county_data/process_servers.rb
|
142
|
+
- lib/sac_county_data/restaurant_inspections.rb
|
112
143
|
- lib/sac_county_data/version.rb
|
113
144
|
- sac_county_data.gemspec
|
145
|
+
- test/building_permits_test.rb
|
146
|
+
- test/county_contracts_test.rb
|
147
|
+
- test/fixtures/vcr_cassettes/building_permits.yml
|
148
|
+
- test/fixtures/vcr_cassettes/county_contracts.yml
|
149
|
+
- test/fixtures/vcr_cassettes/outstanding_checks.yml
|
150
|
+
- test/fixtures/vcr_cassettes/process_servers.yml
|
151
|
+
- test/fixtures/vcr_cassettes/restaurant_inspections.yml
|
114
152
|
- test/outstanding_checks_test.rb
|
153
|
+
- test/process_servers_test.rb
|
154
|
+
- test/restaurant_inspections_test.rb
|
115
155
|
- test/test_helper.rb
|
116
|
-
homepage:
|
156
|
+
homepage: https://github.com/cacciatc/sac_county_data
|
117
157
|
licenses:
|
118
158
|
- MIT
|
119
159
|
metadata: {}
|
@@ -138,5 +178,14 @@ signing_key:
|
|
138
178
|
specification_version: 4
|
139
179
|
summary: A Ruby interface for the Sac County Open Data portal.
|
140
180
|
test_files:
|
181
|
+
- test/building_permits_test.rb
|
182
|
+
- test/county_contracts_test.rb
|
183
|
+
- test/fixtures/vcr_cassettes/building_permits.yml
|
184
|
+
- test/fixtures/vcr_cassettes/county_contracts.yml
|
185
|
+
- test/fixtures/vcr_cassettes/outstanding_checks.yml
|
186
|
+
- test/fixtures/vcr_cassettes/process_servers.yml
|
187
|
+
- test/fixtures/vcr_cassettes/restaurant_inspections.yml
|
141
188
|
- test/outstanding_checks_test.rb
|
189
|
+
- test/process_servers_test.rb
|
190
|
+
- test/restaurant_inspections_test.rb
|
142
191
|
- test/test_helper.rb
|
Binary file
|