fix(test): force special spell purchasable for test

This commit is contained in:
Sabe Jones
2021-04-09 15:41:20 -05:00
parent 46b8e7f725
commit d231eb3023
2 changed files with 7 additions and 4 deletions

View File

@@ -70,6 +70,7 @@ describe('POST /user/buy/:key', () => {
it('buys a special spell', async () => {
const key = 'spookySparkles';
const item = content.special[key];
const stub = sinon.stub(item, 'canOwn').returns(true);
await user.update({ 'stats.gp': 250 });
const res = await user.post(`/user/buy/${key}`);
@@ -82,6 +83,8 @@ describe('POST /user/buy/:key', () => {
expect(res.message).to.equal(t('messageBought', {
itemText: item.text(),
}));
stub.restore();
});
it('allows for bulk purchases', async () => {

View File

@@ -28,10 +28,10 @@
"seasonalShopClosedTitle": "<%= linkStart %>Leslie<%= linkEnd %>",
"seasonalShopTitle": "<%= linkStart %>Seasonal Sorceress<%= linkEnd %>",
"seasonalShopClosedText": "The Seasonal Shop is currently closed!! Its only open during Habiticas four Grand Galas.",
"seasonalShopSummerText": "Happy Summer Splash!! Would you like to buy some rare items? Theyll only be available during the Gala!",
"seasonalShopFallText": "Happy Fall Festival!! Would you like to buy some rare items? Theyll only be available during the Gala!",
"seasonalShopWinterText": "Happy Winter Wonderland!! Would you like to buy some rare items? Theyll only be available during the Gala!",
"seasonalShopSpringText": "Happy Spring Fling!! Would you like to buy some rare items? Theyll only be available during the Gala!",
"seasonalShopSummerText": "Happy Summer Splash!! Would you like to buy some rare items? Be sure to get them before the Gala ends!",
"seasonalShopFallText": "Happy Fall Festival!! Would you like to buy some rare items? Be sure to get them before the Gala ends!",
"seasonalShopWinterText": "Happy Winter Wonderland!! Would you like to buy some rare items? Be sure to get them before the Gala ends!",
"seasonalShopSpringText": "Happy Spring Fling!! Would you like to buy some rare items? Be sure to get them before the Gala ends!",
"seasonalShopFallTextBroken": "Oh.... Welcome to the Seasonal Shop... We're stocking autumn Seasonal Edition goodies, or something... Everything here will be available to purchase during the Fall Festival event each year, but we're only open until October 31... I guess you should to stock up now, or you'll have to wait... and wait... and wait... <strong>*sigh*</strong>",
"seasonalShopBrokenText": "My pavilion!!!!!!! My decorations!!!! Oh, the Dysheartener's destroyed everything :( Please help defeat it in the Tavern so I can rebuild!",
"seasonalShopRebirth": "If you bought any of this equipment in the past but don't currently own it, you can repurchase it in the Rewards Column. Initially, you'll only be able to purchase the items for your current class (Warrior by default), but fear not, the other class-specific items will become available if you switch to that class.",