govkit-ca 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. data/.travis.yml +3 -0
  2. data/README.md +5 -1
  3. data/govkit-ca.gemspec +1 -0
  4. data/lib/gov_kit-ca/postal_code/strategy/base.rb +20 -1
  5. data/lib/gov_kit-ca/postal_code/strategy/cbc_ca.rb +1 -3
  6. data/lib/gov_kit-ca/postal_code/strategy/conservative_ca.rb +9 -6
  7. data/lib/gov_kit-ca/postal_code/strategy/digital-copyright_ca.rb +0 -3
  8. data/lib/gov_kit-ca/postal_code/strategy/greenparty_ca.rb +3 -6
  9. data/lib/gov_kit-ca/postal_code/strategy/ndp_ca.rb +4 -6
  10. data/lib/gov_kit-ca/postal_code/strategy/parl_gc_ca.rb +0 -1
  11. data/lib/gov_kit-ca/postal_code.rb +7 -5
  12. data/lib/gov_kit-ca/version.rb +1 -1
  13. data/lib/gov_kit-ca.rb +0 -2
  14. data/spec/cbc_ca_spec.rb +2 -2
  15. data/spec/conservative_ca_spec.ca +36 -0
  16. data/spec/digital-copyright_ca_spec.rb +21 -22
  17. data/spec/elections_ca_spec.rb +23 -24
  18. data/spec/greenparty_ca_spec.rb +23 -24
  19. data/spec/liberal_ca_spec.rb +24 -22
  20. data/spec/ndp_ca_spec.rb +21 -24
  21. data/spec/postal_code_spec.rb +3 -2
  22. metadata +58 -109
  23. data/spec/fixtures/cbc_ca/A1A1A1.response +0 -11
  24. data/spec/fixtures/cbc_ca/G0C2Y0.response +0 -11
  25. data/spec/fixtures/cbc_ca/H0H0H0.response +0 -11
  26. data/spec/fixtures/cbc_ca/K0A1K0.response +0 -11
  27. data/spec/fixtures/cbc_ca/T5S2B9.response +0 -11
  28. data/spec/fixtures/cbc_ca/X1B1B1.response +0 -11
  29. data/spec/fixtures/conservative_ca/A1A1A1.response +0 -467
  30. data/spec/fixtures/conservative_ca/G0C2Y0.response +0 -467
  31. data/spec/fixtures/conservative_ca/H0H0H0.response +0 -467
  32. data/spec/fixtures/conservative_ca/K0A1K0.response +0 -467
  33. data/spec/fixtures/conservative_ca/T5S2B9.response +0 -467
  34. data/spec/fixtures/conservative_ca/X1B1B1.response +0 -467
  35. data/spec/fixtures/digital-copyright_ca/A1A1A1.response +0 -262
  36. data/spec/fixtures/digital-copyright_ca/G0C2Y0.response +0 -263
  37. data/spec/fixtures/digital-copyright_ca/H0H0H0.response +0 -278
  38. data/spec/fixtures/digital-copyright_ca/K0A1K0.response +0 -264
  39. data/spec/fixtures/digital-copyright_ca/T5S2B9.response +0 -267
  40. data/spec/fixtures/digital-copyright_ca/X1B1B1.response +0 -278
  41. data/spec/fixtures/elections_ca/A1A1A1.response +0 -12
  42. data/spec/fixtures/elections_ca/G0C2Y0.response +0 -12
  43. data/spec/fixtures/elections_ca/H0H0H0.response +0 -11
  44. data/spec/fixtures/elections_ca/K0A1K0.response +0 -11
  45. data/spec/fixtures/elections_ca/T5S2B9.response +0 -12
  46. data/spec/fixtures/elections_ca/X1B1B1.response +0 -11
  47. data/spec/fixtures/greenparty_ca/A1A1A1.response +0 -13
  48. data/spec/fixtures/greenparty_ca/G0C2Y0.response +0 -13
  49. data/spec/fixtures/greenparty_ca/H0H0H0.response +0 -13
  50. data/spec/fixtures/greenparty_ca/K0A1K0.response +0 -13
  51. data/spec/fixtures/greenparty_ca/T5S2B9.response +0 -13
  52. data/spec/fixtures/greenparty_ca/X1B1B1.response +0 -13
  53. data/spec/fixtures/liberal_ca/A1A1A1.response +0 -582
  54. data/spec/fixtures/liberal_ca/G0C2Y0.response +0 -582
  55. data/spec/fixtures/liberal_ca/H0H0H0.response +0 -663
  56. data/spec/fixtures/liberal_ca/K0A1K0.response +0 -663
  57. data/spec/fixtures/liberal_ca/T5S2B9.response +0 -663
  58. data/spec/fixtures/liberal_ca/X1B1B1.response +0 -663
  59. data/spec/fixtures/ndp_ca/A1A1A1.response +0 -12
  60. data/spec/fixtures/ndp_ca/G0C2Y0.response +0 -12
  61. data/spec/fixtures/ndp_ca/H0H0H0.response +0 -12
  62. data/spec/fixtures/ndp_ca/K0A1K0.response +0 -12
  63. data/spec/fixtures/ndp_ca/T5S2B9.response +0 -12
  64. data/spec/fixtures/ndp_ca/X1B1B1.response +0 -12
  65. data/spec/fixtures/parl_gc_ca/A1A1A1.response +0 -337
  66. data/spec/fixtures/parl_gc_ca/G0C2Y0.response +0 -337
  67. data/spec/fixtures/parl_gc_ca/H0H0H0.response +0 -226
  68. data/spec/fixtures/parl_gc_ca/K0A1K0.response +0 -784
  69. data/spec/fixtures/parl_gc_ca/T5S2B9.response +0 -511
  70. data/spec/fixtures/parl_gc_ca/X1B1B1.response +0 -226
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: govkit-ca
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-03-07 00:00:00.000000000 Z
12
+ date: 2012-10-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: httparty
16
- requirement: &70228256054740 !ruby/object:Gem::Requirement
16
+ requirement: !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ~>
@@ -21,10 +21,15 @@ dependencies:
21
21
  version: 0.7.8
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *70228256054740
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ~>
28
+ - !ruby/object:Gem::Version
29
+ version: 0.7.8
25
30
  - !ruby/object:Gem::Dependency
26
31
  name: nokogiri
27
- requirement: &70228256041840 !ruby/object:Gem::Requirement
32
+ requirement: !ruby/object:Gem::Requirement
28
33
  none: false
29
34
  requirements:
30
35
  - - ~>
@@ -32,10 +37,15 @@ dependencies:
32
37
  version: 1.5.0
33
38
  type: :runtime
34
39
  prerelease: false
35
- version_requirements: *70228256041840
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ~>
44
+ - !ruby/object:Gem::Version
45
+ version: 1.5.0
36
46
  - !ruby/object:Gem::Dependency
37
47
  name: yajl-ruby
38
- requirement: &70228256040260 !ruby/object:Gem::Requirement
48
+ requirement: !ruby/object:Gem::Requirement
39
49
  none: false
40
50
  requirements:
41
51
  - - ~>
@@ -43,10 +53,15 @@ dependencies:
43
53
  version: 0.8.2
44
54
  type: :runtime
45
55
  prerelease: false
46
- version_requirements: *70228256040260
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ~>
60
+ - !ruby/object:Gem::Version
61
+ version: 0.8.2
47
62
  - !ruby/object:Gem::Dependency
48
63
  name: rspec
49
- requirement: &70228256037360 !ruby/object:Gem::Requirement
64
+ requirement: !ruby/object:Gem::Requirement
50
65
  none: false
51
66
  requirements:
52
67
  - - ~>
@@ -54,10 +69,15 @@ dependencies:
54
69
  version: 2.6.0
55
70
  type: :development
56
71
  prerelease: false
57
- version_requirements: *70228256037360
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - ~>
76
+ - !ruby/object:Gem::Version
77
+ version: 2.6.0
58
78
  - !ruby/object:Gem::Dependency
59
79
  name: fakeweb
60
- requirement: &70228256015680 !ruby/object:Gem::Requirement
80
+ requirement: !ruby/object:Gem::Requirement
61
81
  none: false
62
82
  requirements:
63
83
  - - ~>
@@ -65,7 +85,28 @@ dependencies:
65
85
  version: 1.3.0
66
86
  type: :development
67
87
  prerelease: false
68
- version_requirements: *70228256015680
88
+ version_requirements: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ~>
92
+ - !ruby/object:Gem::Version
93
+ version: 1.3.0
94
+ - !ruby/object:Gem::Dependency
95
+ name: rake
96
+ requirement: !ruby/object:Gem::Requirement
97
+ none: false
98
+ requirements:
99
+ - - ! '>='
100
+ - !ruby/object:Gem::Version
101
+ version: '0'
102
+ type: :development
103
+ prerelease: false
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ! '>='
108
+ - !ruby/object:Gem::Version
109
+ version: '0'
69
110
  description: GovKit-CA lets you quickly get encapsulated Ruby objects for Canadian
70
111
  civic data.
71
112
  email:
@@ -75,6 +116,7 @@ extensions: []
75
116
  extra_rdoc_files: []
76
117
  files:
77
118
  - .gitignore
119
+ - .travis.yml
78
120
  - Gemfile
79
121
  - LICENSE
80
122
  - README.md
@@ -97,56 +139,9 @@ files:
97
139
  - lib/gov_kit-ca/version.rb
98
140
  - lib/govkit-ca.rb
99
141
  - spec/cbc_ca_spec.rb
142
+ - spec/conservative_ca_spec.ca
100
143
  - spec/digital-copyright_ca_spec.rb
101
144
  - spec/elections_ca_spec.rb
102
- - spec/fixtures/cbc_ca/A1A1A1.response
103
- - spec/fixtures/cbc_ca/G0C2Y0.response
104
- - spec/fixtures/cbc_ca/H0H0H0.response
105
- - spec/fixtures/cbc_ca/K0A1K0.response
106
- - spec/fixtures/cbc_ca/T5S2B9.response
107
- - spec/fixtures/cbc_ca/X1B1B1.response
108
- - spec/fixtures/conservative_ca/A1A1A1.response
109
- - spec/fixtures/conservative_ca/G0C2Y0.response
110
- - spec/fixtures/conservative_ca/H0H0H0.response
111
- - spec/fixtures/conservative_ca/K0A1K0.response
112
- - spec/fixtures/conservative_ca/T5S2B9.response
113
- - spec/fixtures/conservative_ca/X1B1B1.response
114
- - spec/fixtures/digital-copyright_ca/A1A1A1.response
115
- - spec/fixtures/digital-copyright_ca/G0C2Y0.response
116
- - spec/fixtures/digital-copyright_ca/H0H0H0.response
117
- - spec/fixtures/digital-copyright_ca/K0A1K0.response
118
- - spec/fixtures/digital-copyright_ca/T5S2B9.response
119
- - spec/fixtures/digital-copyright_ca/X1B1B1.response
120
- - spec/fixtures/elections_ca/A1A1A1.response
121
- - spec/fixtures/elections_ca/G0C2Y0.response
122
- - spec/fixtures/elections_ca/H0H0H0.response
123
- - spec/fixtures/elections_ca/K0A1K0.response
124
- - spec/fixtures/elections_ca/T5S2B9.response
125
- - spec/fixtures/elections_ca/X1B1B1.response
126
- - spec/fixtures/greenparty_ca/A1A1A1.response
127
- - spec/fixtures/greenparty_ca/G0C2Y0.response
128
- - spec/fixtures/greenparty_ca/H0H0H0.response
129
- - spec/fixtures/greenparty_ca/K0A1K0.response
130
- - spec/fixtures/greenparty_ca/T5S2B9.response
131
- - spec/fixtures/greenparty_ca/X1B1B1.response
132
- - spec/fixtures/liberal_ca/A1A1A1.response
133
- - spec/fixtures/liberal_ca/G0C2Y0.response
134
- - spec/fixtures/liberal_ca/H0H0H0.response
135
- - spec/fixtures/liberal_ca/K0A1K0.response
136
- - spec/fixtures/liberal_ca/T5S2B9.response
137
- - spec/fixtures/liberal_ca/X1B1B1.response
138
- - spec/fixtures/ndp_ca/A1A1A1.response
139
- - spec/fixtures/ndp_ca/G0C2Y0.response
140
- - spec/fixtures/ndp_ca/H0H0H0.response
141
- - spec/fixtures/ndp_ca/K0A1K0.response
142
- - spec/fixtures/ndp_ca/T5S2B9.response
143
- - spec/fixtures/ndp_ca/X1B1B1.response
144
- - spec/fixtures/parl_gc_ca/A1A1A1.response
145
- - spec/fixtures/parl_gc_ca/G0C2Y0.response
146
- - spec/fixtures/parl_gc_ca/H0H0H0.response
147
- - spec/fixtures/parl_gc_ca/K0A1K0.response
148
- - spec/fixtures/parl_gc_ca/T5S2B9.response
149
- - spec/fixtures/parl_gc_ca/X1B1B1.response
150
145
  - spec/greenparty_ca_spec.rb
151
146
  - spec/liberal_ca_spec.rb
152
147
  - spec/ndp_ca_spec.rb
@@ -176,62 +171,15 @@ required_rubygems_version: !ruby/object:Gem::Requirement
176
171
  version: '0'
177
172
  requirements: []
178
173
  rubyforge_project: govkit-ca
179
- rubygems_version: 1.8.12
174
+ rubygems_version: 1.8.24
180
175
  signing_key:
181
176
  specification_version: 3
182
177
  summary: Easy access to Canadian civic data around the web
183
178
  test_files:
184
179
  - spec/cbc_ca_spec.rb
180
+ - spec/conservative_ca_spec.ca
185
181
  - spec/digital-copyright_ca_spec.rb
186
182
  - spec/elections_ca_spec.rb
187
- - spec/fixtures/cbc_ca/A1A1A1.response
188
- - spec/fixtures/cbc_ca/G0C2Y0.response
189
- - spec/fixtures/cbc_ca/H0H0H0.response
190
- - spec/fixtures/cbc_ca/K0A1K0.response
191
- - spec/fixtures/cbc_ca/T5S2B9.response
192
- - spec/fixtures/cbc_ca/X1B1B1.response
193
- - spec/fixtures/conservative_ca/A1A1A1.response
194
- - spec/fixtures/conservative_ca/G0C2Y0.response
195
- - spec/fixtures/conservative_ca/H0H0H0.response
196
- - spec/fixtures/conservative_ca/K0A1K0.response
197
- - spec/fixtures/conservative_ca/T5S2B9.response
198
- - spec/fixtures/conservative_ca/X1B1B1.response
199
- - spec/fixtures/digital-copyright_ca/A1A1A1.response
200
- - spec/fixtures/digital-copyright_ca/G0C2Y0.response
201
- - spec/fixtures/digital-copyright_ca/H0H0H0.response
202
- - spec/fixtures/digital-copyright_ca/K0A1K0.response
203
- - spec/fixtures/digital-copyright_ca/T5S2B9.response
204
- - spec/fixtures/digital-copyright_ca/X1B1B1.response
205
- - spec/fixtures/elections_ca/A1A1A1.response
206
- - spec/fixtures/elections_ca/G0C2Y0.response
207
- - spec/fixtures/elections_ca/H0H0H0.response
208
- - spec/fixtures/elections_ca/K0A1K0.response
209
- - spec/fixtures/elections_ca/T5S2B9.response
210
- - spec/fixtures/elections_ca/X1B1B1.response
211
- - spec/fixtures/greenparty_ca/A1A1A1.response
212
- - spec/fixtures/greenparty_ca/G0C2Y0.response
213
- - spec/fixtures/greenparty_ca/H0H0H0.response
214
- - spec/fixtures/greenparty_ca/K0A1K0.response
215
- - spec/fixtures/greenparty_ca/T5S2B9.response
216
- - spec/fixtures/greenparty_ca/X1B1B1.response
217
- - spec/fixtures/liberal_ca/A1A1A1.response
218
- - spec/fixtures/liberal_ca/G0C2Y0.response
219
- - spec/fixtures/liberal_ca/H0H0H0.response
220
- - spec/fixtures/liberal_ca/K0A1K0.response
221
- - spec/fixtures/liberal_ca/T5S2B9.response
222
- - spec/fixtures/liberal_ca/X1B1B1.response
223
- - spec/fixtures/ndp_ca/A1A1A1.response
224
- - spec/fixtures/ndp_ca/G0C2Y0.response
225
- - spec/fixtures/ndp_ca/H0H0H0.response
226
- - spec/fixtures/ndp_ca/K0A1K0.response
227
- - spec/fixtures/ndp_ca/T5S2B9.response
228
- - spec/fixtures/ndp_ca/X1B1B1.response
229
- - spec/fixtures/parl_gc_ca/A1A1A1.response
230
- - spec/fixtures/parl_gc_ca/G0C2Y0.response
231
- - spec/fixtures/parl_gc_ca/H0H0H0.response
232
- - spec/fixtures/parl_gc_ca/K0A1K0.response
233
- - spec/fixtures/parl_gc_ca/T5S2B9.response
234
- - spec/fixtures/parl_gc_ca/X1B1B1.response
235
183
  - spec/greenparty_ca_spec.rb
236
184
  - spec/liberal_ca_spec.rb
237
185
  - spec/ndp_ca_spec.rb
@@ -239,3 +187,4 @@ test_files:
239
187
  - spec/spec.opts
240
188
  - spec/spec_helper.rb
241
189
  - spec/strategy_set_spec.rb
190
+ has_rdoc:
@@ -1,11 +0,0 @@
1
- HTTP/1.1 200 OK
2
- Server: Apache/2.2.3 (Red Hat) PHP/5.1.6
3
- X-Powered-By: PHP/5.1.6
4
- X-Origin-Server: web17:sb17
5
- Content-Type: text/html
6
- Cache-Control: max-age=30
7
- Expires: Wed, 07 Mar 2012 17:13:27 GMT
8
- Date: Wed, 07 Mar 2012 17:12:57 GMT
9
- Connection: keep-alive
10
-
11
- [{"rid":"007","name":"St. John's South - Mount Pearl"}]
@@ -1,11 +0,0 @@
1
- HTTP/1.1 200 OK
2
- Server: Apache/2.2.3 (Red Hat) PHP/5.1.6
3
- X-Powered-By: PHP/5.1.6
4
- X-Origin-Server: web17:sb17
5
- Content-Type: text/html
6
- Cache-Control: max-age=30
7
- Expires: Wed, 07 Mar 2012 17:13:27 GMT
8
- Date: Wed, 07 Mar 2012 17:12:57 GMT
9
- Connection: keep-alive
10
-
11
- [{"rid":"052","name":"Gasp\u00e9sie - \u00celes-de-la-Madeleine"}]
@@ -1,11 +0,0 @@
1
- HTTP/1.1 404 Not Found
2
- Server: Apache/2.2.3 (Red Hat) PHP/5.1.6
3
- X-Powered-By: PHP/5.1.6
4
- X-Origin-Server: web16:sb17
5
- Content-Length: 0
6
- Content-Type: text/html
7
- Vary: Accept-Encoding
8
- Cache-Control: max-age=27
9
- Expires: Wed, 07 Mar 2012 17:13:12 GMT
10
- Date: Wed, 07 Mar 2012 17:12:45 GMT
11
- Connection: keep-alive
@@ -1,11 +0,0 @@
1
- HTTP/1.1 200 OK
2
- Server: Apache/2.2.3 (Red Hat) PHP/5.1.6
3
- X-Powered-By: PHP/5.1.6
4
- X-Origin-Server: web17:sb17
5
- Content-Type: text/html
6
- Cache-Control: max-age=30
7
- Expires: Wed, 07 Mar 2012 17:13:27 GMT
8
- Date: Wed, 07 Mar 2012 17:12:57 GMT
9
- Connection: keep-alive
10
-
11
- [{"rid":"133","name":"Glengarry - Prescott - Russell"},{"rid":"159","name":"Nepean - Carleton"},{"rid":"170","name":"Ottawa - Orl\u00e9ans"},{"rid":"171","name":"Ottawa South"}]
@@ -1,11 +0,0 @@
1
- HTTP/1.1 200 OK
2
- Server: Apache/2.2.3 (Red Hat) PHP/5.1.6
3
- X-Powered-By: PHP/5.1.6
4
- X-Origin-Server: web17:sb17
5
- Content-Type: text/html
6
- Cache-Control: max-age=30
7
- Expires: Wed, 07 Mar 2012 17:13:27 GMT
8
- Date: Wed, 07 Mar 2012 17:12:57 GMT
9
- Connection: keep-alive
10
-
11
- [{"rid":"257","name":"Edmonton - Spruce Grove"},{"rid":"255","name":"Edmonton - St. Albert"}]
@@ -1,11 +0,0 @@
1
- HTTP/1.1 404 Not Found
2
- Server: Apache/2.2.3 (Red Hat) PHP/5.1.6
3
- X-Powered-By: PHP/5.1.6
4
- X-Origin-Server: web16:sb17
5
- Content-Length: 0
6
- Content-Type: text/html
7
- Vary: Accept-Encoding
8
- Cache-Control: max-age=27
9
- Expires: Wed, 07 Mar 2012 17:13:12 GMT
10
- Date: Wed, 07 Mar 2012 17:12:45 GMT
11
- Connection: keep-alive