public async Task ThenCannotProceed_IfStatusIsErroneous()
            {
                // Arrange
                IAS4Response as4Response = CreateEmptyAS4ResponseWithStatus(HttpStatusCode.InternalServerError);
                var          handler     = new EmptyBodyResponseHandler(CreateAnonymousNextHandler());

                // Act
                StepResult actualResult = await handler.HandleResponse(as4Response);

                // Assert
                Assert.False(actualResult.CanProceed);
                AssertNoChangeInPModes(as4Response, actualResult);
            }
            public async Task ThenHandlerReturnsSameResultedMessage_IfStatusIsAccepted()
            {
                // Arrange
                IAS4Response as4Response = CreateEmptyAS4ResponseWithStatus(HttpStatusCode.Accepted);
                var          handler     = new EmptyBodyResponseHandler(CreateAnonymousNextHandler());

                // Act
                StepResult actualResult = await handler.HandleResponse(as4Response);

                // Assert
                Assert.False(actualResult.CanProceed);
                AssertNoChangeInPModes(as4Response, actualResult);
            }
            public async Task ThenNextHandlerGetsTheResponse_IfAS4MessageIsReceived()
            {
                // Arrange
                AS4Message   as4Message  = AS4Message.Create(new Error($"error-{Guid.NewGuid()}", $"user-{Guid.NewGuid()}"));
                IAS4Response as4Response = CreateAS4ResponseWithResultedMessage(as4Message);

                var spyHandler = new SpyAS4ResponseHandler();
                var handler    = new EmptyBodyResponseHandler(spyHandler);

                // Act
                await handler.HandleResponse(as4Response);

                // Assert
                Assert.True(spyHandler.IsCalled);
            }