From e9029eef09936902fc0cc2732404203b0b8f61c3 Mon Sep 17 00:00:00 2001 From: Jonathan Bobel Date: Thu, 17 Apr 2025 10:58:06 -0400 Subject: [PATCH] Update activityChart.test.js --- tests/javascripts/activityChart.test.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/javascripts/activityChart.test.js b/tests/javascripts/activityChart.test.js index 4e0393e7e..3d0087ec1 100644 --- a/tests/javascripts/activityChart.test.js +++ b/tests/javascripts/activityChart.test.js @@ -18,6 +18,12 @@ Object.defineProperty(HTMLElement.prototype, 'clientWidth', { }); // beforeAll hook to set up the DOM and load D3.js script +beforeAll(() => { + jest.spyOn(Intl, 'DateTimeFormat').mockImplementation(() => ({ + resolvedOptions: () => ({ timeZone: 'UTC' }) + })); +}); + beforeAll(done => { // Set up the DOM with the D3 script included document.body.innerHTML = `