public void PublishMessage_WithCreateMessageDTO_ReturnsTwitterAccessor() { // Arrange var queryExecutor = CreateMessageQueryExecutor(); var parameters = A.Fake <IPublishMessageParameters>(); var reqDTO = A.Fake <ICreateMessageDTO>(); var resDTO = A.Fake <ICreateMessageDTO>(); var query = TestHelper.GenerateString(); ArrangeQueryGeneratorPublishMessage(parameters, query, reqDTO); _fakeTwitterAccessor.ArrangeExecutePostQueryJsonBody(query, reqDTO, resDTO); // Act var result = queryExecutor.PublishMessage(parameters); // Assert Assert.AreEqual(result, resDTO); }