No copayer nickname on 1-1 wallets

This commit is contained in:
Ivan Socolsky 2014-09-12 11:10:45 -03:00
commit 8d7e420524
2 changed files with 11 additions and 3 deletions

View file

@ -57,13 +57,21 @@ describe("Unit: Controllers", function() {
expect(saveAsLastCall.blob.type).equal('text/plain;charset=utf-8');
});
it('Backup controller should name backup correctly', function() {
it('Backup controller should name backup correctly for multiple copayers', function() {
scope.wallet.setEnc('1234567');
expect(saveAsLastCall).equal(null);
scope.downloadBackup();
expect(saveAsLastCall.filename).equal('myNickname-myTESTwullet-testID-keybackup.json.aes');
});
it('Backup controller should name backup correctly for 1-1 wallet', function() {
scope.wallet.setEnc('1234567');
expect(saveAsLastCall).equal(null);
scope.wallet.totalCopayers = 1;
scope.downloadBackup();
expect(saveAsLastCall.filename).equal('myTESTwullet-testID-keybackup.json.aes');
});
it('Backup controller #delete', function() {
expect(scope.wallet).not.equal(undefined);
scope.deleteWallet();