From 83a430afad9a81b3c754174a0e4280bd59e2fcee Mon Sep 17 00:00:00 2001 From: Sabe Jones Date: Wed, 28 Aug 2024 14:39:52 -0500 Subject: [PATCH] fix broken test (#15304) Co-authored-by: Phillip Thelen --- test/common/libs/shops.test.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/common/libs/shops.test.js b/test/common/libs/shops.test.js index c936884b2d..ad43ee688d 100644 --- a/test/common/libs/shops.test.js +++ b/test/common/libs/shops.test.js @@ -53,9 +53,11 @@ describe('shops', () => { }); it('does not contain past scheduled premium hatching potions', async () => { + clock = sinon.useFakeTimers(new Date('2024-04-01T09:00:00.000Z')); const potions = shared.shops.getMarketCategories(user).find(x => x.identifier === 'premiumHatchingPotions'); - expect(potions.items.filter(x => x.key === 'Aquatic' || x.key === 'Celestial').length).to.eql(0); + expect(potions.items.filter(x => x.key === 'Aquatic' || x.key === 'Celestial').length, 'Aquatic or Celestial found').to.eql(0); }); + it('returns end date for scheduled premium potions', async () => { const potions = shared.shops.getMarketCategories(user).find(x => x.identifier === 'premiumHatchingPotions'); potions.items.forEach(potion => {