public async Task AcceptUser_ShouldReturnFalse_WhenGroupIsMissing()
        {
            // Arrange
            var expectedMessage = "Specified group doesn't exist!";

            _unitOfWork.Setup(x => x.Groups.GetById(It.IsAny <int>()))
            .ReturnsAsync(() => null);

            // Act
            var result = await _sut.AcceptUser(It.IsAny <int>(), It.IsAny <int>());

            // Assert
            Assert.False(result.Key);
            Assert.Equal(expectedMessage, result.Value);
        }
 public async Task <IActionResult> AcceptUser(int groupId, int userId)
 {
     // We only check that we are logged in
     // TODO: add check if user is admin or owner in order to
     //       accept or reject user
     return(Ok(await _groupsService.AcceptUser(groupId, userId)));
 }