public async Task GetAllMethodReturnsCreditCardDetails() { var creditCardService = new CreditCardService(_creditCardRepositoryMock.Object, _tokenisationServiceMock.Object); var creditCards = await creditCardService.GetAll(); Assert.AreEqual(creditCards.Count(), 2); }
/// <summary> /// Get a MovementViewModel object /// </summary> /// <param name="movement"></param> /// <returns></returns> private async Task <MovementViewModel> GetViewModel(Movement movement) { return(new MovementViewModel { Movement = movement, Accounts = await _accountService.GetAll(), Categories = await _categoryService.GetAll(), Subcategories = await _subcategoryService.GetAll(), Projects = await _projectService.GetAllActiveProjects(), CreditCards = await _creditCardService.GetAll() }); }
public IEnumerable <CreditCard> GetCreditCards() { return(service.GetAll()); }
public async Task <ActionResult <DataCollection <CreditCardDTO> > > GetAll(int page, int take) { return(await _CreditCardService.GetAll(page, take)); }
// GET: CreditCards public async Task <ActionResult> Index() { return(View(await _service.GetAll())); }