Browse Source

fix tests

activeAddress
Ivan Socolsky 10 years ago
parent
commit
50c217c994
  1. 14
      test/integration.js

14
test/integration.js

@ -218,10 +218,11 @@ describe('Copay server', function() {
it('should fail when requesting for non-existent copayer', function(done) { it('should fail when requesting for non-existent copayer', function(done) {
CopayServer.getInstanceWithAuth({ CopayServer.getInstanceWithAuth({
copayerId: 'ads', copayerId: 'ads',
message: 'dummy', message: TestData.message.text,
signature: 'dummy', signature: TestData.message.signature,
}, function(err, server) { }, function(err, server) {
err.should.contain('Copayer not found'); err.code.should.equal('NOTAUTHORIZED');
err.message.should.contain('Copayer not found');
done(); done();
}); });
}); });
@ -233,7 +234,8 @@ describe('Copay server', function() {
message: 'dummy', message: 'dummy',
signature: 'dummy', signature: 'dummy',
}, function(err, server) { }, function(err, server) {
err.should.contain('Invalid signature'); err.code.should.equal('NOTAUTHORIZED');
err.message.should.contain('Invalid signature');
done(); done();
}); });
}); });
@ -1253,8 +1255,8 @@ describe('Copay server', function() {
server.getNotifications({ server.getNotifications({
limit: 5, limit: 5,
reverse: true, reverse: true,
maxTs: Date.now()/1000, maxTs: Date.now() / 1000,
minTs: Date.now()/1000-1000, minTs: Date.now() / 1000 - 1000,
}, function(err, notifications) { }, function(err, notifications) {
should.not.exist(err); should.not.exist(err);
var types = _.pluck(notifications, 'type'); var types = _.pluck(notifications, 'type');

Loading…
Cancel
Save