Skip to content

Commit

Permalink
🎨 address format with spotless
Browse files Browse the repository at this point in the history
  • Loading branch information
simonhir committed Sep 5, 2024
1 parent d875a28 commit bf2ae72
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ void testListAddresses_Success()
throws AddressServiceIntegrationServerErrorException, AddressServiceIntegrationException, AddressServiceIntegrationClientErrorException {
when(adressenMuenchenApi.listAdressen(any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(),
any(), any(), any()))
.thenReturn(Mono.just(muenchenAdresseResponse));
.thenReturn(Mono.just(muenchenAdresseResponse));
final MuenchenAdresseResponse result = addressMunich.listAddresses(listAddressesModel);
assertThat(result).isEqualTo(muenchenAdresseResponse);
}
Expand All @@ -126,7 +126,7 @@ void testListAddresses_Success()
void testListAddresses_ClientErrorException() {
when(adressenMuenchenApi.listAdressen(any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(),
any(), any(), any()))
.thenThrow(new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Bad Request"));
.thenThrow(new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Bad Request"));
assertThatThrownBy(() -> addressMunich.listAddresses(listAddressesModel))
.isInstanceOf(AddressServiceIntegrationClientErrorException.class);
}
Expand All @@ -135,7 +135,7 @@ void testListAddresses_ClientErrorException() {
void testListAddresses_ServerErrorException() {
when(adressenMuenchenApi.listAdressen(any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(),
any(), any(), any()))
.thenThrow(new HttpServerErrorException(HttpStatus.INTERNAL_SERVER_ERROR, "Internal Server Error"));
.thenThrow(new HttpServerErrorException(HttpStatus.INTERNAL_SERVER_ERROR, "Internal Server Error"));
assertThatThrownBy(() -> addressMunich.listAddresses(listAddressesModel))
.isInstanceOf(AddressServiceIntegrationServerErrorException.class);
}
Expand All @@ -144,7 +144,7 @@ void testListAddresses_ServerErrorException() {
void testListAddresses_RestClientException() {
when(adressenMuenchenApi.listAdressen(any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(), any(),
any(), any(), any()))
.thenThrow(new RestClientException("REST exception"));
.thenThrow(new RestClientException("REST exception"));
assertThatThrownBy(() -> addressMunich.listAddresses(listAddressesModel))
.isInstanceOf(AddressServiceIntegrationException.class);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public BundesweiteAdresseResponse searchAddresses(SearchAddressesGermanyModel se
try {
return this.addressGermanyApi.searchAddresses(searchAddressesGermanyModel);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand All @@ -46,7 +46,7 @@ public MuenchenAdresse checkAddress(CheckAddressesModel checkAddressesModel) thr
try {
return this.addressMunichApi.checkAddress(checkAddressesModel);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand All @@ -56,7 +56,7 @@ public MuenchenAdresseResponse listAddresses(ListAddressesModel listAddressesMod
try {
return this.addressMunichApi.listAddresses(listAddressesModel);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand All @@ -66,7 +66,7 @@ public AenderungResponse listChanges(ListAddressChangesModel listAddressChangesM
try {
return this.addressMunichApi.listChanges(listAddressChangesModel);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand All @@ -77,7 +77,7 @@ public MuenchenAdresseResponse searchAddresses(SearchAddressesModel searchAddres
try {
return this.addressMunichApi.searchAddresses(searchAddressesModel);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand All @@ -88,7 +88,7 @@ public AddressDistancesModel searchAddressesGeo(SearchAddressesGeoModel searchAd
try {
return this.addressMunichApi.searchAddressesGeo(searchAddressesGeoModel);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand All @@ -98,7 +98,7 @@ public Strasse findStreetsById(long streetId) throws AddressServiceIntegrationEx
try {
return this.streetsMunichApi.findStreetsById(streetId);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand All @@ -108,7 +108,7 @@ public StrasseResponse listStreets(ListStreetsModel listStreetsModel) throws Add
try {
return this.streetsMunichApi.listStreets(listStreetsModel);
} catch (final
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
AddressServiceIntegrationException | AddressServiceIntegrationServerErrorException | AddressServiceIntegrationClientErrorException exception) {
throw new AddressServiceIntegrationException(exception.getMessage(), exception);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@ BundesweiteAdresseResponse searchAddresses(final SearchAddressesGermanyModel sea
/**
* Search for addresses in Munich.
*/
MuenchenAdresseResponse searchAddresses(final SearchAddressesModel searchAddressesModel) throws
AddressServiceIntegrationException;
MuenchenAdresseResponse searchAddresses(final SearchAddressesModel searchAddressesModel) throws AddressServiceIntegrationException;

/**
* Search for addresses in Munich.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,7 @@ public StraenMnchenApi addressServiceStraenMnchenApi() {
public AddressClientOutPort addressClientOutPort(
final AddressGermanyApi addressGermanyApi,
final AddressMunichApi addressMunichApi,
final StreetsMunichApi streetsMunichApi
) {
final StreetsMunichApi streetsMunichApi) {
return new AddressClientOutAdapter(addressGermanyApi, addressMunichApi, streetsMunichApi);
}

Expand Down

0 comments on commit bf2ae72

Please sign in to comment.