Skip to content

Commit

Permalink
Sonar cleanup: RegistryAwareClientBuilderTest (#325)
Browse files Browse the repository at this point in the history
Don't hide instance fields. Instead, re-assign them in the tests.
  • Loading branch information
sleberknight authored Jun 18, 2024
1 parent bb348d5 commit 9c17eb7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ void shouldNotThrowException_WhenTlsConfigProvider_ThrowsExceptionConvertingToSS
.doesNotThrowAnyException();
verify(tlsConfig).toSSLContext();

var client = builder.tlsConfigProvider(tlsConfigProvider).build();
client = builder.tlsConfigProvider(tlsConfigProvider).build();
assertThat(client.getSslContext())
.describedAs("Should still have a non-null, default SSLContext")
.isNotNull();
Expand All @@ -208,7 +208,7 @@ private static String getUnitTestKeyStorePath() {

@Test
void shouldAcceptGivenRegistryClient() {
var registryClient = mock(RegistryClient.class);
registryClient = mock(RegistryClient.class);

client = builder.registryClient(registryClient).build();

Expand Down

0 comments on commit 9c17eb7

Please sign in to comment.