From 88ed5d5ec169b21a9a21b82ba475efb94894c3dd Mon Sep 17 00:00:00 2001 From: Alexandre Pretto Nunes Date: Mon, 22 Dec 2014 15:47:05 -0200 Subject: #202 fix identification if mail is in trash --- web-ui/test/spec/services/model/mail.spec.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'web-ui/test/spec/services') diff --git a/web-ui/test/spec/services/model/mail.spec.js b/web-ui/test/spec/services/model/mail.spec.js index 53ac0845..35c4bc9b 100644 --- a/web-ui/test/spec/services/model/mail.spec.js +++ b/web-ui/test/spec/services/model/mail.spec.js @@ -6,10 +6,11 @@ require(['services/model/mail'], function (Mail) { describe('services/model/mail', function () { describe('parsing', function () { describe('a single email', function () { - var sentMail, draftMail, receivedMail, receivedMailWithCC, rawMailWithMultipleTo; + var sentMail, draftMail, receivedMail, receivedMailWithCC, rawMailWithMultipleTo, mailInTrash; beforeEach(function () { sentMail = Mail.create(Pixelated.testData().rawMail.sent); draftMail = Mail.create(Pixelated.testData().rawMail.draft); + mailInTrash = Mail.create(Pixelated.testData().rawMail.trash); receivedMail = Mail.create(Pixelated.testData().rawMail.received); receivedMailWithCC = Mail.create(Pixelated.testData().rawMail.receivedWithCC); rawMailWithMultipleTo = Mail.create(Pixelated.testData().rawMail.rawMailWithMultipleTo); @@ -27,6 +28,10 @@ require(['services/model/mail'], function (Mail) { expect(receivedMail.isSentMail()).toBe(false); expect(receivedMail.isDraftMail()).toBe(false); }); + + it('correctly identifies a mail in trash', function () { + expect(mailInTrash.isInTrash()).toBe(true); + }); }); describe('multipart email', function () { -- cgit v1.2.3