fixed tests

This commit is contained in:
Andris Reinman 2017-11-19 14:58:01 +02:00
parent c6bf1784b6
commit 6db874255c
3 changed files with 5 additions and 6 deletions

View file

@ -1731,16 +1731,13 @@ class UserHandler {
},
{
specialUse: '\\Junk'
},
{
specialUse: '\\Archive'
}
];
let uidValidity = Math.floor(Date.now() / 1000);
return defaultMailboxes.map(mailbox => ({
path: translation[mailbox.specialUse || mailbox.path] || mailbox.path,
path: mailbox.path === 'INBOX' ? 'INBOX' : translation[mailbox.specialUse || mailbox.path] || mailbox.path,
specialUse: mailbox.specialUse,
uidValidity,
uidNext: 1,

View file

@ -6,7 +6,10 @@
"scripts": {
"test": "mongo --eval 'db.dropDatabase()' wildduck-test && redis-cli -n 13 flushdb && NODE_ENV=test grunt"
},
"keywords": ["imap", "mail server"],
"keywords": [
"imap",
"mail server"
],
"author": "Andris Reinman",
"license": "EUPL-1.1",
"devDependencies": {

View file

@ -554,7 +554,6 @@ describe('Send multiple messages', function() {
let folders = result.children.map(mbox => ({ name: mbox.name, specialUse: mbox.specialUse || false }));
expect(folders).to.deep.equal([
{ name: 'INBOX', specialUse: false },
{ name: 'Archive', specialUse: '\\Archive' },
{ name: 'Drafts', specialUse: '\\Drafts' },
{ name: 'Junk', specialUse: '\\Junk' },
{ name: 'Sent Mail', specialUse: '\\Sent' },