Sha256: d704a79acf6797cf7ee356bf4e94992c97c6c8583d0d55bf2964b339dbc07f30
Contents?: true
Size: 613 Bytes
Versions: 1
Compression:
Stored size: 613 Bytes
Contents
# encoding: utf-8 require 'test_helper' class CacheTest < Test::Unit::TestCase def test_second_occurrence_of_request_is_cache_hit Geocoder::Configuration.cache = {} Geocoder::Lookup.all_services_except_test.each do |l| Geocoder::Configuration.lookup = l set_api_key!(l) results = Geocoder.search("Madison Square Garden") assert !results.first.cache_hit, "Lookup #{l} returned erroneously cached result." results = Geocoder.search("Madison Square Garden") assert results.first.cache_hit, "Lookup #{l} did not return cached result." end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
geocoder-1.1.5 | test/cache_test.rb |