private void SetupController()
        {
            var request = new Mock <HttpRequestBase>();

            _controller = new AnswerController(_unitOfWork.Object);
            _user       = new Mock <IPrincipal>();

            _controller.MockContext(request, _user);
            _identity = _user.MockIdentity(_answer1.AppUserId);
        }
        public void Setup()
        {
            _context            = new iKnowContext();
            _contextAfterAction = new iKnowContext();
            _controller         = new AnswerController(new UnitOfWork(new iKnowContext()));

            _currentUser = new Mock <IPrincipal>();
            _controller.MockContext(new Mock <HttpRequestBase>(), _currentUser);

            _firstUserInDb = _context.Users.First();
            _currentUser.MockIdentity(_firstUserInDb.Id);
        }