Merge pull request 'feat: added one integration test (closes #19)' (#20) from feat-19-add-integration-test into main

Reviewed-on: #20
pull/21/head
Inga 🏳‍🌈 12 months ago
commit 8758bfb17e
  1. 13
      src/transaction/transaction.controller.spec.ts

@ -173,4 +173,17 @@ describe('TransactionController Unit Tests', () => {
expect(result).to.eql('{"amount":"4.17","currency":"EUR"}');
});
it('returns correct amount for small transactions', async () => {
const mockTransactionInput: TransactionInput = {
date: '2021-01-05',
amount: '0.01',
currency: 'EUR',
client_id: 1,
};
const result = await transactionController.commission(mockTransactionInput);
expect(result).to.eql('{"amount":"0.05","currency":"EUR"}');
});
});

Loading…
Cancel
Save