コード例 #1
0
        public void GetAllCommunities()
        {
            var res = communityService.GetAllAsync().Result;

            Assert.IsTrue(res.Success);
            Assert.AreEqual(3, res.Result.Count());
        }
コード例 #2
0
        public async Task <ActionResult> Search()
        {
            //fazer verificação
            CommunityService service = CommunityService.GetInstance();
            var result = await service.GetAllAsync();

            return(View(result.Result));
        }
コード例 #3
0
        public async Task <JsonResult> GetCommunityList()
        {
            var list = await _communityService.GetAllAsync();

            return(Success(list));
        }