boot(); $this->geocoder = $kernel->getContainer()->get('pcm_geocode.geocoder'); } public function testGeocodeInstance(): void { $this->assertInstanceOf(Geocoder::class, $this->geocoder); } public function testGeocodePostcodeReturnsNullOnInvalidInput(): void { sleep(1); $this->assertNull($this->geocoder->geocodePostcode('')); } public function testGeocodePostcodeReturnsGeoCoordinates(): GeoCoordinates { sleep(1); $geoCoords = $this->geocoder->geocodePostcode(self::POSTCODE); $this->assertNotNull($geoCoords); return $geoCoords; } /** * @depends testGeocodePostcodeReturnsGeoCoordinates */ public function testCoordinatesAreSet(GeoCoordinates $geoCoordinates): void { $this->assertIsFloat($geoCoordinates->latitude); $this->assertIsFloat($geoCoordinates->longitude); } private function getMappableEntity(): MappableInterface { return new class implements MappableInterface { use MappableTrait; }; } }