diff --git a/test/api/v3/integration/user/auth/POST-register_local.test.js b/test/api/v3/integration/user/auth/POST-register_local.test.js index e56a6b132c..11c30cd072 100644 --- a/test/api/v3/integration/user/auth/POST-register_local.test.js +++ b/test/api/v3/integration/user/auth/POST-register_local.test.js @@ -129,7 +129,9 @@ describe('POST /user/auth/local/register', () => { expect(tags[5].name).to.eql(t('defaultTag6')); expect(tags[6].name).to.eql(t('defaultTag7')); }); + }); + context('does not provide default tags and tasks', async () => { it('for Android', async () => { api = requester( null, @@ -154,34 +156,11 @@ describe('POST /user/auth/local/register', () => { let rewards = await requests.get('/tasks/user?type=rewards'); let tags = await requests.get('/tags'); - expect(habits).to.have.a.lengthOf(2); - expect(habits[0].text).to.eql(t('defaultHabit4Text')); - expect(habits[0].notes).to.eql(t('defaultHabit4Notes')); - expect(habits[1].text).to.eql(t('defaultHabit5Text')); - expect(habits[1].notes).to.eql(t('defaultHabit5Notes')); - - expect(dailys).to.have.a.lengthOf(1); - expect(dailys[0].text).to.eql(t('defaultDaily1Text')); - expect(dailys[0].notes).to.eql(''); - - expect(todos).to.have.a.lengthOf(2); - expect(todos[0].text).to.eql(t('defaultTodo1Text')); - expect(todos[0].notes).to.eql(t('defaultTodoNotes')); - expect(todos[1].text).to.eql(t('defaultTodo2Text')); - expect(todos[1].notes).to.eql(t('defaultTodo2Notes')); - - expect(rewards).to.have.a.lengthOf(1); - expect(rewards[0].text).to.eql(t('defaultReward2Text')); - expect(rewards[0].notes).to.eql(t('defaultReward2Notes')); - - expect(tags).to.have.a.lengthOf(7); - expect(tags[0].name).to.eql(t('defaultTag1')); - expect(tags[1].name).to.eql(t('defaultTag2')); - expect(tags[2].name).to.eql(t('defaultTag3')); - expect(tags[3].name).to.eql(t('defaultTag4')); - expect(tags[4].name).to.eql(t('defaultTag5')); - expect(tags[5].name).to.eql(t('defaultTag6')); - expect(tags[6].name).to.eql(t('defaultTag7')); + expect(habits).to.have.a.lengthOf(0); + expect(dailys).to.have.a.lengthOf(0); + expect(todos).to.have.a.lengthOf(0); + expect(rewards).to.have.a.lengthOf(0); + expect(tags).to.have.a.lengthOf(0); }); it('for iOS', async () => { @@ -208,34 +187,11 @@ describe('POST /user/auth/local/register', () => { let rewards = await requests.get('/tasks/user?type=rewards'); let tags = await requests.get('/tags'); - expect(habits).to.have.a.lengthOf(2); - expect(habits[0].text).to.eql(t('defaultHabit4Text')); - expect(habits[0].notes).to.eql(t('defaultHabit4Notes')); - expect(habits[1].text).to.eql(t('defaultHabit5Text')); - expect(habits[1].notes).to.eql(t('defaultHabit5Notes')); - - expect(dailys).to.have.a.lengthOf(1); - expect(dailys[0].text).to.eql(t('defaultDaily1Text')); - expect(dailys[0].notes).to.eql(''); - - expect(todos).to.have.a.lengthOf(2); - expect(todos[0].text).to.eql(t('defaultTodo1Text')); - expect(todos[0].notes).to.eql(t('defaultTodoNotes')); - expect(todos[1].text).to.eql(t('defaultTodo2Text')); - expect(todos[1].notes).to.eql(t('defaultTodo2Notes')); - - expect(rewards).to.have.a.lengthOf(1); - expect(rewards[0].text).to.eql(t('defaultReward2Text')); - expect(rewards[0].notes).to.eql(t('defaultReward2Notes')); - - expect(tags).to.have.a.lengthOf(7); - expect(tags[0].name).to.eql(t('defaultTag1')); - expect(tags[1].name).to.eql(t('defaultTag2')); - expect(tags[2].name).to.eql(t('defaultTag3')); - expect(tags[3].name).to.eql(t('defaultTag4')); - expect(tags[4].name).to.eql(t('defaultTag5')); - expect(tags[5].name).to.eql(t('defaultTag6')); - expect(tags[6].name).to.eql(t('defaultTag7')); + expect(habits).to.have.a.lengthOf(0); + expect(dailys).to.have.a.lengthOf(0); + expect(todos).to.have.a.lengthOf(0); + expect(rewards).to.have.a.lengthOf(0); + expect(tags).to.have.a.lengthOf(0); }); });