1
0
mirror of https://gitlab.com/timvisee/send.git synced 2024-11-10 13:13:00 +01:00

testing failure

This commit is contained in:
Abhinav Adduri 2017-07-17 10:38:19 -07:00
parent d287f67ac0
commit e0847e08c3
2 changed files with 5 additions and 12 deletions

View File

@ -78,12 +78,8 @@ class FileReceiver extends EventEmitter {
resolve(decrypted);
})
}),
new Promise((resolve, reject) => {
resolve(fdata.filename);
}),
new Promise((resolve, reject) => {
resolve(hexToArray(fdata.aad));
})
fdata.filename,
hexToArray(fdata.aad)
]);
}).then(([decrypted, fname, proposedHash]) => {
this.emit('hashing', true);
@ -96,12 +92,8 @@ class FileReceiver extends EventEmitter {
} else {
this.emit('safe', true);
return Promise.all([
new Promise((resolve, reject) => {
resolve(decrypted);
}),
new Promise((resolve, reject) => {
resolve(fname);
})
decrypted,
fname
]);
}
})

View File

@ -40,6 +40,7 @@ describe('File Sender', function() {
})
it('Should get a loading event emission', function() {
assert.fail();
const file = new FakeFile('hello_world.txt', ['This is some data.'])
const fs = new FileSender(file);
let testLoading = true;