@@ -165,7 +165,7 @@ public function testGeocoder()
165165
166166 public function testCacheIsUsed ()
167167 {
168- $ cacheKey = str_slug (strtolower (urlencode ('1600 Pennsylvania Ave NW, Washington, DC 20500, USA ' )));
168+ $ cacheKey = md5 ( str_slug (strtolower (urlencode ('1600 Pennsylvania Ave NW, Washington, DC 20500, USA ' ) )));
169169
170170 $ result = app ('geocoder ' )->geocode ('1600 Pennsylvania Ave NW, Washington, DC 20500, USA ' )
171171 ->get ();
@@ -265,14 +265,14 @@ public function testGetProvider()
265265
266266 public function testJapaneseCharacterGeocoding ()
267267 {
268- $ cacheKey = str_slug (strtolower (urlencode ('108-0075 東京都港区港南2丁目16-3 ' )));
268+ $ cacheKey = md5 ( str_slug (strtolower (urlencode ('108-0075 東京都港区港南2丁目16-3 ' ) )));
269269
270270 app ('geocoder ' )->geocode ('108-0075 東京都港区港南2丁目16-3 ' )
271271 ->get ();
272272
273273 $ this ->assertEquals (
274274 $ cacheKey ,
275- '108-0075e69db1e4baace983bde6b8afe58cbae6b8afe58d97efbc92e4b881e79baeefbc91efbc96efbc8defbc93 '
275+ md5 ( '108-0075e69db1e4baace983bde6b8afe58cbae6b8afe58d97efbc92e4b881e79baeefbc91efbc96efbc8defbc93 ' )
276276 );
277277 $ this ->assertTrue (app ('cache ' )->has ("geocoder- {$ cacheKey }" ));
278278 }
@@ -304,7 +304,7 @@ public function testItHandlesOnlyCityAndState()
304304
305305 public function testEmptyResultsAreNotCached ()
306306 {
307- $ cacheKey = str_slug (strtolower (urlencode ('_ ' )));
307+ $ cacheKey = md5 ( str_slug (strtolower (urlencode ('_ ' ) )));
308308
309309 Geocoder::geocode ('_ ' )->get ();
310310
0 commit comments