X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/5682fb4d2465024639d6e0006c664f203ba773f5..d122ea16f8dc45bc4c4e004f37eb2d1b96df52d4:/test/controllers/geocoder_controller_test.rb diff --git a/test/controllers/geocoder_controller_test.rb b/test/controllers/geocoder_controller_test.rb index 1a1435182..0459eb294 100644 --- a/test/controllers/geocoder_controller_test.rb +++ b/test/controllers/geocoder_controller_test.rb @@ -236,9 +236,9 @@ class GeocoderControllerTest < ActionController::TestCase ## # Test identification of US zipcodes def test_identify_us_postcode - [ - "12345", - "12345-6789" + %w[ + 12345 + 12345-6789 ].each do |code| post :search, :params => { :query => code } assert_response :success @@ -489,11 +489,11 @@ class GeocoderControllerTest < ActionController::TestCase assert_select "ul.results-list", 0 else assert_select "ul.results-list", 1 do - assert_select "p.search_results_entry", results.count + assert_select "li.search_results_entry", results.count results.each do |result| attrs = result.collect { |k, v| "[data-#{k}='#{v}']" }.join("") - assert_select "p.search_results_entry a.set_position#{attrs}", result[:name] + assert_select "li.search_results_entry a.set_position#{attrs}", result[:name] end end end