Fixed 'Use all funds' link for amounts below fee

This commit is contained in:
Ivan Socolsky 2014-09-08 17:31:18 -03:00
commit 9ee04fe45f
2 changed files with 9 additions and 1 deletions

View file

@ -411,6 +411,13 @@ describe("Unit: Controllers", function() {
var amount = scope.getAvailableAmount();
expect(amount).to.equal(123356);
});
it('should return 0 if available amount below minimum fee', function() {
inject(function($compile, $rootScope, $controller) {
$rootScope.availableBalance = 1;
});
var amount = scope.getAvailableAmount();
expect(amount).to.equal(0);
});
});
describe('Import Controller', function() {