public async Task AsHttpResponseData_ExceptionIsAnUnexpectedException_ReturnsResponseWithGenericErrorAndStatusInternalServerError()
        {
            // arrange
            var          request = new MockedHttpRequestData(new MockedFunctionContext());
            const string internalErrorMessage = "Something is not right";
            var          exception            = new ArgumentNullException(internalErrorMessage);

            // act
            var actual = await exception.AsHttpResponseDataAsync(request.HttpRequestData).ConfigureAwait(false);

            var actualFunctionError = JsonSerializer.Deserialize <ErrorResponse>(
                ((MemoryStream)actual.Body).ToArray(),
                new JsonSerializerOptions {
                PropertyNamingPolicy = JsonNamingPolicy.CamelCase
            }) !;
            var error = actualFunctionError.Error;

            // assert
            Assert.Equal(HttpStatusCode.InternalServerError, actual.StatusCode);
            Assert.Equal("INTERNAL_ERROR", error.Code);
            Assert.Equal("An error occured while processing the request.", error.Message);
            Assert.Null(error.Target);
            Assert.Null(error.Details);
        }