public async Task CanDeserializeLogsDetailResponse() { var client = new iBanFirstClient(new HttpClient(new FakeHttpMessageHandler <Log>())); var tx = await client.Logs.Get("account-id"); Assert.NotNull(tx); Assert.IsType <Log>(tx.Result); }
public async Task CanDeserializeTradesListResponse() { var client = new iBanFirstClient(new HttpClient(new FakeHttpMessageHandler <List <Trade> >())); var tx = await client.Trades.List(TransactionStatus.all); Assert.NotNull(tx); Assert.IsType <List <Trade> >(tx.Result); }
public async Task CanDeserializeLogsListResponse() { var client = new iBanFirstClient(new HttpClient(new FakeHttpMessageHandler <List <Log> >())); var tx = await client.Logs.List(); Assert.NotNull(tx); Assert.IsType <List <Log> >(tx.Result); }
public async Task CanDeserializeWalletDetailResponse() { var client = new iBanFirstClient(new HttpClient(new FakeHttpMessageHandler <WalletDetail>())); var tx = await client.Wallets.Get("wallet-id"); Assert.NotNull(tx); Assert.IsType <WalletDetail>(tx.Result); }
public async Task CanDeserializeFinancialMovementsResponse() { var client = new iBanFirstClient(new HttpClient(new FakeHttpMessageHandler <List <FinancialMovementList> >())); var tx = await client.FinancialMovements.List(); Assert.NotNull(tx); Assert.IsType <List <FinancialMovementList> >(tx.Result); }
public async Task CanDeserializeExternalBankAccountListResponse() { var client = new iBanFirstClient(new HttpClient(new FakeHttpMessageHandler <List <ExternalBankAccount> >())); var tx = await client.ExternalBankAccounts.List(); Assert.NotNull(tx); Assert.IsType <List <ExternalBankAccount> >(tx.Result); }
public async Task CanMakeTwoRequestsFromSameClientInstance() { var client = new iBanFirstClient(new HttpClient(new FakeHttpMessageHandler <WalletDetail>())); var tx = await client.Wallets.Get("wallet-id"); Assert.NotNull(tx); Assert.IsType <WalletDetail>(tx.Result); var tx2 = await client.Wallets.Get("wallet-id"); Assert.NotNull(tx2); Assert.IsType <WalletDetail>(tx2.Result); }
public void CanInstantiateClient() { var client = new iBanFirstClient(new HttpClient()); Assert.NotNull(client); }