Sha256: 339971018474391a2dab39c9e25c1eb6b202565c7238499d0da1fc6667820545
Contents?: true
Size: 554 Bytes
Versions: 6
Compression:
Stored size: 554 Bytes
Contents
module GovKit module CA module PostalCode module Strategy class GreenPartyCa < Base base_uri 'www.greenparty.ca' http_method :head path '/search/green_geo/<%= @postal_code %>' private def electoral_districts! [ response.headers['location'][/\d+\z/] ] end def valid? response.headers['location'] != 'http://www.greenparty.ca/find_your_riding' end end StrategySet.register GreenPartyCa end end end end
Version data entries
6 entries across 6 versions & 1 rubygems