Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Commit

Permalink
Merge pull request #408 from alepop/402-increase-load-transaction
Browse files Browse the repository at this point in the history
Load 20 transaction instead 10 - Closes #402
  • Loading branch information
reyraa authored Jun 15, 2017
2 parents 50104cd + d87a911 commit 027dc3f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion features/transactions.feature
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ Feature: Transactions tab
Scenario: should show transactions
Given I'm logged in as "genesis"
When I click tab number 1
Then I should see table with 10 lines
Then I should see table with 20 lines
2 changes: 1 addition & 1 deletion src/components/transactions/transactions.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ app.component('transactions', {
this.loaded = false;
}

const limit = Math.max(10, this.transactions.length + (showMore ? 10 : 0));
const limit = Math.max(20, this.transactions.length + (showMore ? 20 : 0));
return this.loadTransactions(limit);
}

Expand Down
4 changes: 2 additions & 2 deletions test/components/transactions/transactions.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ describe('transactions component controller', () => {
expect(controller.loaded).to.equal(undefined);
});

it('calls accountApi.transactions.get(account.get().address, limit) with limit = 10 by default', () => {
mock.expects('get').withArgs(account.get().address, 10).returns(transactionsDeferred.promise);
it('calls accountApi.transactions.get(account.get().address, limit) with limit = 20 by default', () => {
mock.expects('get').withArgs(account.get().address, 20).returns(transactionsDeferred.promise);
controller.update();
transactionsDeferred.reject();

Expand Down

0 comments on commit 027dc3f

Please sign in to comment.