@@ -64,12 +64,12 @@ public function testLocationResultContainsExpectedFieldsForAnAmericanIp(): void
64
64
$ provider = new IP2LocationBinary ($ this ->binaryFile );
65
65
$ results = $ provider ->geocodeQuery (GeocodeQuery::create ('8.8.8.8 ' ));
66
66
67
- $ this ->assertInstanceOf (' Geocoder\Model\AddressCollection ' , $ results );
67
+ $ this ->assertInstanceOf (\ Geocoder \Model \AddressCollection::class , $ results );
68
68
$ this ->assertCount (1 , $ results );
69
69
70
70
/** @var Location $result */
71
71
$ result = $ results ->first ();
72
- $ this ->assertInstanceOf (' \Geocoder\Model\Address ' , $ result );
72
+ $ this ->assertInstanceOf (\Geocoder \Model \Address::class , $ result );
73
73
74
74
$ this ->assertEqualsWithDelta (37.405990600586 , $ result ->getCoordinates ()->getLatitude (), 0.001 );
75
75
$ this ->assertEqualsWithDelta (-122.07851409912 , $ result ->getCoordinates ()->getLongitude (), 0.001 );
@@ -92,12 +92,12 @@ public function testLocationResultContainsExpectedFieldsForAChinaIp(): void
92
92
$ provider = new IP2LocationBinary ($ this ->binaryFile );
93
93
$ results = $ provider ->geocodeQuery (GeocodeQuery::create ('123.123.123.123 ' ));
94
94
95
- $ this ->assertInstanceOf (' Geocoder\Model\AddressCollection ' , $ results );
95
+ $ this ->assertInstanceOf (\ Geocoder \Model \AddressCollection::class , $ results );
96
96
$ this ->assertCount (1 , $ results );
97
97
98
98
/** @var Location $result */
99
99
$ result = $ results ->first ();
100
- $ this ->assertInstanceOf (' \Geocoder\Model\Address ' , $ result );
100
+ $ this ->assertInstanceOf (\Geocoder \Model \Address::class , $ result );
101
101
102
102
$ this ->assertEqualsWithDelta (39.907501220703 , $ result ->getCoordinates ()->getLatitude (), 0.001 );
103
103
$ this ->assertEqualsWithDelta (116.39723205566 , $ result ->getCoordinates ()->getLongitude (), 0.001 );
@@ -120,12 +120,12 @@ public function testGeocodeWithRealIPv6(): void
120
120
$ provider = new IP2LocationBinary ($ this ->binaryFile );
121
121
$ results = $ provider ->geocodeQuery (GeocodeQuery::create ('2001:4860:4860::8888 ' ));
122
122
123
- $ this ->assertInstanceOf (' Geocoder\Model\AddressCollection ' , $ results );
123
+ $ this ->assertInstanceOf (\ Geocoder \Model \AddressCollection::class , $ results );
124
124
$ this ->assertCount (1 , $ results );
125
125
126
126
/** @var Location $result */
127
127
$ result = $ results ->first ();
128
- $ this ->assertInstanceOf (' \Geocoder\Model\Address ' , $ result );
128
+ $ this ->assertInstanceOf (\Geocoder \Model \Address::class , $ result );
129
129
130
130
$ this ->assertEqualsWithDelta (37.386051 , $ result ->getCoordinates ()->getLatitude (), 0.001 );
131
131
$ this ->assertEqualsWithDelta (-122.083847 , $ result ->getCoordinates ()->getLongitude (), 0.001 );
@@ -151,12 +151,12 @@ public function testFindLocationByIp(string $ip, ?string $expectedCity, ?string
151
151
$ provider = new IP2LocationBinary ($ this ->binaryFile );
152
152
$ results = $ provider ->geocodeQuery (GeocodeQuery::create ($ ip ));
153
153
154
- $ this ->assertInstanceOf (' Geocoder\Model\AddressCollection ' , $ results );
154
+ $ this ->assertInstanceOf (\ Geocoder \Model \AddressCollection::class , $ results );
155
155
$ this ->assertCount (1 , $ results );
156
156
157
157
/** @var Location $result */
158
158
$ result = $ results ->first ();
159
- $ this ->assertInstanceOf (' \Geocoder\Model\Address ' , $ result );
159
+ $ this ->assertInstanceOf (\Geocoder \Model \Address::class , $ result );
160
160
$ this ->assertEquals ($ expectedCity , $ result ->getLocality ());
161
161
$ this ->assertEquals ($ expectedCountry , $ result ->getCountry ()->getName ());
162
162
}
0 commit comments