Node.js based forum software built for the modern web
test: fix tests
Barış Soner Uşaklı173c604a2c21
diff --git a/src/user/create.js b/src/user/create.jsindex 610d614e81..154285bee9 100644--- a/src/user/create.js+++ b/src/user/create.js@@ -50,7 +50,7 @@ module.exports = function (User) {lastonline: timestamp,status: 'online',};- ['picture', 'fullname', 'location', 'birthday'].forEach((field) => {+ ['picture', 'fullname', 'birthday'].forEach((field) => {if (data[field]) {userData[field] = data[field];}diff --git a/test/user.js b/test/user.jsindex 9b7fc88f18..84d8711260 100644--- a/test/user.js+++ b/test/user.js@@ -737,8 +737,6 @@ describe('User', () => {username: 'updatedUserName',email: '[email protected]',fullname: 'updatedFullname',- website: 'http://nodebb.org',- location: 'izmir',groupTitle: 'testGroup',birthday: '01/01/1980',signature: 'nodebb is good',@@ -747,7 +745,7 @@ describe('User', () => {const result = await apiUser.update({ uid: uid }, { ...data, password: '123456', invalid: 'field' });assert.equal(result.username, 'updatedUserName');assert.equal(result.userslug, 'updatedusername');- assert.equal(result.location, 'izmir');+ assert.equal(result.fullname, 'updatedFullname');const userData = await db.getObject(`user:${uid}`);Object.keys(data).forEach((key) => {