Return null instead of throwing
This commit is contained in:
@@ -33,11 +33,10 @@ class GeocodeTest extends KernelTestCase
|
||||
$this->assertInstanceOf(Geocoder::class, $this->geocoder);
|
||||
}
|
||||
|
||||
public function testGeocodePostcodeThrowsOnInvalidInput(): void
|
||||
public function testGeocodePostcodeReturnsNullOnInvalidInput(): void
|
||||
{
|
||||
sleep(1);
|
||||
$this->expectException(\Exception::class);
|
||||
$this->geocoder->geocodePostcode('aaaaaaaa');
|
||||
$this->assertNull($this->geocoder->geocodePostcode(''));
|
||||
}
|
||||
|
||||
public function testGeocodePostcodeReturnsLatLonModel(): void
|
||||
|
||||
Reference in New Issue
Block a user