Add translated gear name to open-mystery-item call (#11306)

* Add translated gear name to open-mystery-item call

* Fix test

* fix mystery item text language
This commit is contained in:
Phillip Thelen
2019-08-16 19:40:49 +02:00
committed by Matteo Pagliazzi
parent c8466eec98
commit 6784d23a7c
3 changed files with 6 additions and 1 deletions

View File

@@ -36,7 +36,9 @@ describe('shared.ops.openMysteryItem', () => {
expect(user.items.gear.owned[mysteryItemKey]).to.be.true;
expect(message).to.equal(i18n.t('mysteryItemOpened'));
expect(data).to.eql(content.gear.flat[mysteryItemKey]);
let item = _.cloneDeep(content.gear.flat[mysteryItemKey]);
item.text = content.gear.flat[mysteryItemKey].text();
expect(data).to.eql(item);
expect(user.notifications.length).to.equal(0);
});
});