From 14061b814e7cb7e5c97379b71c4b5eace534f069 Mon Sep 17 00:00:00 2001 From: Rashid Khan Date: Tue, 8 Mar 2016 08:53:57 -0700 Subject: [PATCH] Update error timeout and test --- src/ui/public/notify/__tests__/notifier.js | 4 ++-- src/ui/public/notify/notifier.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ui/public/notify/__tests__/notifier.js b/src/ui/public/notify/__tests__/notifier.js index a7febe7c5b93b..60630b5df951a 100644 --- a/src/ui/public/notify/__tests__/notifier.js +++ b/src/ui/public/notify/__tests__/notifier.js @@ -43,8 +43,8 @@ describe('Notifier', function () { expect(notify('error').title).to.equal('Error'); }); - it('sets lifetime to Infinity', function () { - expect(notify('error').lifetime).to.equal(Infinity); + it('sets lifetime to 5 minutes', function () { + expect(notify('error').lifetime).to.equal(300000); }); it('allows reporting', function () { diff --git a/src/ui/public/notify/notifier.js b/src/ui/public/notify/notifier.js index 332961e94e41c..e2ff33b3901e2 100644 --- a/src/ui/public/notify/notifier.js +++ b/src/ui/public/notify/notifier.js @@ -229,7 +229,7 @@ Notifier.prototype.error = function (err, cb) { content: formatMsg(err, this.from), icon: 'warning', title: 'Error', - lifetime: Infinity, + lifetime: 300000, actions: ['report', 'accept'], stack: formatStack(err) }, cb);