Skip to content
Snippets Groups Projects
Commit 899a34b5 authored by Alex Reisner's avatar Alex Reisner
Browse files

Compare class name as string.

Tests were failing like this:
  <Geocoder::Result::Nominatim> expected but was
  <"Geocoder::Result::Nominatim">
parent c407c2e5
No related branches found
No related tags found
No related merge requests found
...@@ -60,18 +60,18 @@ class GeocoderTest < GeocoderTestCase ...@@ -60,18 +60,18 @@ class GeocoderTest < GeocoderTestCase
def test_geocode_with_custom_lookup_param def test_geocode_with_custom_lookup_param
v = PlaceWithCustomLookup.new(*geocoded_object_params(:msg)) v = PlaceWithCustomLookup.new(*geocoded_object_params(:msg))
v.geocode v.geocode
assert_equal Geocoder::Result::Nominatim, v.result_class assert_equal "Geocoder::Result::Nominatim", v.result_class.to_s
end end
def test_geocode_with_custom_lookup_proc_param def test_geocode_with_custom_lookup_proc_param
v = PlaceWithCustomLookupProc.new(*geocoded_object_params(:msg)) v = PlaceWithCustomLookupProc.new(*geocoded_object_params(:msg))
v.geocode v.geocode
assert_equal Geocoder::Result::Nominatim, v.result_class assert_equal "Geocoder::Result::Nominatim", v.result_class.to_s
end end
def test_reverse_geocode_with_custom_lookup_param def test_reverse_geocode_with_custom_lookup_param
v = PlaceReverseGeocodedWithCustomLookup.new(*reverse_geocoded_object_params(:msg)) v = PlaceReverseGeocodedWithCustomLookup.new(*reverse_geocoded_object_params(:msg))
v.reverse_geocode v.reverse_geocode
assert_equal Geocoder::Result::Nominatim, v.result_class assert_equal "Geocoder::Result::Nominatim", v.result_class.to_s
end end
end end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment