Skip to content

Commit e902b66

Browse files
committed
fix GeoPlugin provider tests
1 parent 2925a38 commit e902b66

File tree

2 files changed

+16
-15
lines changed

2 files changed

+16
-15
lines changed

tests/.cached_responses/f740d06107ce2f0d84b55f13bacf38572393d44c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
s:753:"{
1+
s:747:"{
22
"geoplugin_request":"66.147.244.214",
3-
"geoplugin_status":200,
3+
"geoplugin_status":206,
44
"geoplugin_credit":"Some of the returned data includes GeoLite data created by MaxMind, available from <a href=\\'http:\/\/www.maxmind.com\\'>http:\/\/www.maxmind.com<\/a>.",
5-
"geoplugin_city":"Provo",
6-
"geoplugin_region":"UT",
7-
"geoplugin_areaCode":"801",
8-
"geoplugin_dmaCode":"770",
5+
"geoplugin_city":"",
6+
"geoplugin_region":"NY",
7+
"geoplugin_areaCode":"0",
8+
"geoplugin_dmaCode":"0",
99
"geoplugin_countryCode":"US",
1010
"geoplugin_countryName":"United States",
1111
"geoplugin_continentCode":"NA",
12-
"geoplugin_latitude":"40.218102",
13-
"geoplugin_longitude":"-111.613297",
14-
"geoplugin_regionCode":"UT",
15-
"geoplugin_regionName":"Utah",
12+
"geoplugin_latitude":"40.711102",
13+
"geoplugin_longitude":"-73.946899",
14+
"geoplugin_regionCode":"NY",
15+
"geoplugin_regionName":"New York",
1616
"geoplugin_currencyCode":"USD",
1717
"geoplugin_currencySymbol":"&#36;",
1818
"geoplugin_currencySymbol_UTF8":"$",

tests/Geocoder/Tests/Provider/GeoPluginTest.php

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -102,11 +102,12 @@ public function testGeocodeWithRealIPv4()
102102
$this->assertCount(1, $results);
103103

104104
$result = $results[0];
105-
$this->assertEquals(40.218102, $result->getLatitude(), '', 0.0001);
106-
$this->assertEquals(-111.613297, $result->getLongitude(), '', 0.0001);
107-
$this->assertEquals('Provo', $result->getLocality());
108-
$this->assertEquals('Utah', $result->getRegion()->getName());
109-
$this->assertEquals('UT', $result->getRegion()->getCode());
105+
106+
$this->assertEquals(40.711101999999997, $result->getLatitude(), '', 0.0001);
107+
$this->assertEquals(-73.946899000000002, $result->getLongitude(), '', 0.0001);
108+
$this->assertNull($result->getLocality());
109+
$this->assertEquals('New York', $result->getRegion()->getName());
110+
$this->assertEquals('NY', $result->getRegion()->getCode());
110111
$this->assertEquals('United States', $result->getCountry()->getName());
111112
$this->assertEquals('US', $result->getCountry()->getCode());
112113
}

0 commit comments

Comments
 (0)