    @Test
    public void with_cause_constructor_should_translate_null_response_headers_to_empty_list() {

        // given
        List<Pair<String, String>> loggingDetails = Collections.emptyList();
        List<ApiError> apiErrors = Arrays.asList(apiError1, apiError2);

        // when
        ApiException apiException = new ApiException(apiErrors, loggingDetails, null, exceptionMessage, cause);

        // then
        assertThat(apiException.getExtraResponseHeaders())
            .isNotNull()
            .isEmpty();
    }