### Question:
ResultApiRequestDataBuildUpdater implements AttemptAuditEventResultBuilderUpdater<ResultApiRequestData> { @Override public void update(AuditProto.AttemptAuditEventResult.Builder builder, ResultApiRequestData resultEventData) { AuditProto.ResultApiRequestData.Builder resultApiRequestDataBuilder = builderProvider.getNewResultApiRequestDataBuilder(); doIfTrue(resultEventData.getResponseParameters(), StringUtils::isNotEmpty, resultApiRequestDataBuilder::setResponseParameters); builder.setResultApiRequestData(resultApiRequestDataBuilder.build()); } ResultApiRequestDataBuildUpdater(ResultApiRequestDataBuilderProvider builderProvider); @Override void update(AuditProto.AttemptAuditEventResult.Builder builder, ResultApiRequestData resultEventData); @Override Class<ResultApiRequestData> getType();  }### Answer:
@Test void testUpdateWhenResponseParametersAreEmpty() { when(resultEventData.getResponseParameters()).thenReturn(""); underTest.update(mockAttemptAuditEventResultBuilder, resultEventData); verify(mockResultApiRequestDataBuilder, never()).setResponseParameters(anyString()); }
@Test void testUpdateWhenResponseParameterIsNull() { when(resultEventData.getResponseParameters()).thenReturn(null); underTest.update(mockAttemptAuditEventResultBuilder, resultEventData); verify(mockResultApiRequestDataBuilder, never()).setResponseParameters(anyString()); }
@Test void testUpdateWhenResponseParametersAreNotEmpty() { String parametersValue = "someValue"; when(resultEventData.getResponseParameters()).thenReturn(parametersValue); underTest.update(mockAttemptAuditEventResultBuilder, resultEventData); verify(mockResultApiRequestDataBuilder, times(1)).setResponseParameters(anyString()); verify(mockResultApiRequestDataBuilder, times(1)).setResponseParameters(parametersValue); }