CredentialsDto extends BaseDto { @JsonIgnore public boolean requiresMerging() { return requiresMerging; } CredentialsDto();  CredentialsDto(
            final String tenantId,
            final String deviceId,
            final List<CommonCredential> credentials,
            final String version); String getTenantId(); void setTenantId(final String tenantId); String getDeviceId(); void setDeviceId(final String deviceId); List<CommonCredential> getCredentials(); void setCredentials(final List<CommonCredential> credentials); @JsonIgnore boolean requiresMerging(); void createMissingSecretIds(); @JsonIgnore CredentialsDto merge(final CredentialsDto otherCredentialsDto);  }
@Test void testNewSecretWithoutIdDoesNotRequireMerging() { final PskCredential updatedCred = Credentials.createPSKCredential("psk-id", "other-key"); final CredentialsDto updatedDto = new CredentialsDto("tenant", "device", List.of(updatedCred), "1"); assertThat(updatedDto.requiresMerging()).isFalse(); }