Api v3 Migration (WIP) (#7131)

* v3 migration: remove old code and polish user migration

* v3 migration: start to work on challenges

* wip v3 migration

* wip v3 migration: fix _id -> id for reminders, tags and checklists
This commit is contained in:
Matteo Pagliazzi
2016-04-30 18:34:16 +02:00
parent f69a566178
commit 6380161321
24 changed files with 350 additions and 203 deletions

View File

@@ -80,14 +80,14 @@ describe('PUT /tasks/:id', () => {
let savedDaily = await user.put(`/tasks/${daily._id}`, {
reminders: [
{_id: id1, time: new Date(), startDate: new Date()},
{_id: id2, time: new Date(), startDate: new Date()},
{id: id1, time: new Date(), startDate: new Date()},
{id: id2, time: new Date(), startDate: new Date()},
],
});
expect(savedDaily.reminders.length).to.equal(2);
expect(savedDaily.reminders[0]._id).to.equal(id1);
expect(savedDaily.reminders[1]._id).to.equal(id2);
expect(savedDaily.reminders[0].id).to.equal(id1);
expect(savedDaily.reminders[1].id).to.equal(id2);
});
});