public async Task GetAllIntrests_Should_Return_Success_Result()
        {
            var interestRepository = new InterestRepository(_pearUpContext);
            var result             = await interestRepository.GetAllInterests();

            result.IsSuccessed.Should().BeTrue();
            result.Value.Should().BeEquivalentTo(_interestsList);
        }
Пример #2
0
        public ActionResult GetAllInterestsForUser(int userId)
        {
            var listOfInterests = _interestRepository.GetAllInterests(userId);

            return(Ok(listOfInterests));
        }
Пример #3
0
        public ActionResult GetAllInterests()
        {
            var interestList = InterestRepository.GetAllInterests();

            return(Created($"api/getAllInterests", interestList));
        }