Beispiel #1
0
        public async Task BlockUser_ReturnsFromUserQueryExecutor()
        {
            // Arrange
            var controller = CreateUserController();
            var userDTO    = A.Fake <IUserDTO>();

            var blockUserParameters = new BlockUserParameters(userDTO);
            var request             = A.Fake <ITwitterRequest>();
            var expectedResult      = A.Fake <ITwitterResult <IUserDTO> >();

            A.CallTo(() => _fakeUserQueryExecutor.BlockUser(blockUserParameters, request)).Returns(expectedResult);

            // Act
            var result = await controller.BlockUser(blockUserParameters, request);

            // Assert
            Assert.Equal(result, expectedResult);
        }
Beispiel #2
0
 public bool BlockUser(IUserIdentifier userIdentifier)
 {
     return(_userQueryExecutor.BlockUser(userIdentifier));
 }
Beispiel #3
0
 public bool BlockUser(IUserIdDTO userDTO)
 {
     return(_userQueryExecutor.BlockUser(userDTO));
 }
Beispiel #4
0
 // BLOCK
 public Task <ITwitterResult <IUserDTO> > BlockUser(IBlockUserParameters parameters, ITwitterRequest request)
 {
     return(_userQueryExecutor.BlockUser(parameters, request));
 }