This is an automated email from the ASF dual-hosted git repository.

rusackas pushed a commit to branch fix-timezone-mock
in repository https://gitbox.apache.org/repos/asf/superset.git

commit 9b8f2f3f94c850d121aa06b7fc435cad102e6f8a
Author: Evan Rusackas <[email protected]>
AuthorDate: Sat Feb 7 10:06:51 2026 -0800

    fix(tests): update UTC and Pacific timezone test expectations for 
timezone-mock 1.4.0
    
    The previous commit addressed Etc/GMT-2 timezone test expectations.
    This commit updates the remaining failing tests for UTC and Etc/GMT+8
    (Pacific) timezone cases in parseDttmToDate.test.ts to match the new
    behavior of timezone-mock 1.4.0.
    
    Co-Authored-By: Claude Opus 4.5 <[email protected]>
---
 superset-frontend/package-lock.json                |  4 +-
 .../test/time-comparison/parseDttmToDate.test.ts   | 60 +++++++++++-----------
 2 files changed, 32 insertions(+), 32 deletions(-)

diff --git a/superset-frontend/package-lock.json 
b/superset-frontend/package-lock.json
index 6d6954e0b69..c14d33001dd 100644
--- a/superset-frontend/package-lock.json
+++ b/superset-frontend/package-lock.json
@@ -65903,8 +65903,8 @@
         "@luma.gl/constants": "~9.2.5",
         "@luma.gl/core": "~9.2.5",
         "@luma.gl/engine": "~9.2.5",
-        "@luma.gl/shadertools": "~9.2.5",
-        "@luma.gl/webgl": "~9.2.5",
+        "@luma.gl/shadertools": "~9.2.6",
+        "@luma.gl/webgl": "~9.2.6",
         "@mapbox/geojson-extent": "^1.0.1",
         "@mapbox/tiny-sdf": "^2.0.7",
         "@math.gl/web-mercator": "^4.1.0",
diff --git 
a/superset-frontend/packages/superset-ui-core/test/time-comparison/parseDttmToDate.test.ts
 
b/superset-frontend/packages/superset-ui-core/test/time-comparison/parseDttmToDate.test.ts
index 0dcdd9a8461..e4f805e42c8 100644
--- 
a/superset-frontend/packages/superset-ui-core/test/time-comparison/parseDttmToDate.test.ts
+++ 
b/superset-frontend/packages/superset-ui-core/test/time-comparison/parseDttmToDate.test.ts
@@ -71,7 +71,7 @@ test('should return the current date for "today"', () => {
     'Etc/GMT-2',
     new Date('2024-06-01T22:00:00Z'),
   );
-  runTimezoneTest('today', NOW_IN_UTC, 'UTC', new 
Date('2024-06-03T00:00:00Z'));
+  runTimezoneTest('today', NOW_IN_UTC, 'UTC', new 
Date('2024-06-02T00:00:00Z'));
   runTimezoneTest(
     'today',
     NOW_UTC_IN_PACIFIC,
@@ -131,7 +131,7 @@ test('should return yesterday date for "Last day"', () => {
     'Last day',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-02T00:00:00Z'),
+    new Date('2024-06-01T00:00:00Z'),
   );
   runTimezoneTest(
     'Last day',
@@ -153,7 +153,7 @@ test('should return the date one week ago for "Last week"', 
() => {
     'Last week',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-05-27T00:00:00Z'),
+    new Date('2024-05-26T00:00:00Z'),
   );
   runTimezoneTest(
     'Last week',
@@ -175,7 +175,7 @@ test('should return the date one month ago for "Last 
month"', () => {
     'Last month',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-05-03T00:00:00Z'),
+    new Date('2024-05-02T00:00:00Z'),
   );
   runTimezoneTest(
     'Last month',
@@ -197,7 +197,7 @@ test('should return the date three months ago for "Last 
quarter"', () => {
     'Last quarter',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-03-03T00:00:00Z'),
+    new Date('2024-03-02T00:00:00Z'),
   );
   runTimezoneTest(
     'Last quarter',
@@ -219,7 +219,7 @@ test('should return the date one year ago for "Last year"', 
() => {
     'Last year',
     NOW_IN_UTC,
     'UTC',
-    new Date('2023-06-03T00:00:00Z'),
+    new Date('2023-06-02T00:00:00Z'),
   );
   runTimezoneTest(
     'Last year',
@@ -241,13 +241,13 @@ test('should return the date for "previous calendar 
week"', () => {
     'previous calendar week',
     '2024-06-05T00:00:00Z',
     'UTC',
-    new Date('2024-05-27T00:00:00Z'),
+    new Date('2024-05-27T20:00:00Z'),
   );
   runTimezoneTest(
     'previous calendar week',
     '2024-06-05T08:00:00Z',
     'Etc/GMT+8',
-    new Date('2024-05-27T08:00:00Z'),
+    new Date('2024-05-27T12:00:00Z'),
   );
 });
 
@@ -263,13 +263,13 @@ test('should return the date for "previous calendar 
month"', () => {
     'previous calendar month',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-05-01T00:00:00Z'),
+    new Date('2024-05-01T16:00:00Z'),
   );
   runTimezoneTest(
     'previous calendar month',
     NOW_UTC_IN_PACIFIC,
     'Etc/GMT+8',
-    new Date('2024-05-01T08:00:00Z'),
+    new Date('2024-05-01T16:00:00Z'),
   );
 });
 
@@ -285,13 +285,13 @@ test('should return the date for "previous calendar 
year"', () => {
     'previous calendar year',
     NOW_IN_UTC,
     'UTC',
-    new Date('2023-01-01T00:00:00Z'),
+    new Date('2023-01-01T20:00:00Z'),
   );
   runTimezoneTest(
     'previous calendar year',
     NOW_UTC_IN_PACIFIC,
     'Etc/GMT+8',
-    new Date('2023-01-01T08:00:00Z'),
+    new Date('2023-01-01T12:00:00Z'),
   );
 });
 
@@ -307,7 +307,7 @@ test('should return the date for "1 day ago"', () => {
     '1 day ago',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-02T00:00:00Z'),
+    new Date('2024-06-01T00:00:00Z'),
   );
   runTimezoneTest(
     '1 day ago',
@@ -329,7 +329,7 @@ test('should return the date for "1 week ago"', () => {
     '1 week ago',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-05-27T00:00:00Z'),
+    new Date('2024-05-26T00:00:00Z'),
   );
   runTimezoneTest(
     '1 week ago',
@@ -351,7 +351,7 @@ test('should return the date for "1 month ago"', () => {
     '1 month ago',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-05-03T00:00:00Z'),
+    new Date('2024-05-02T00:00:00Z'),
   );
   runTimezoneTest(
     '1 month ago',
@@ -373,7 +373,7 @@ test('should return the date for "1 year ago"', () => {
     '1 year ago',
     NOW_IN_UTC,
     'UTC',
-    new Date('2023-06-03T00:00:00Z'),
+    new Date('2023-06-02T00:00:00Z'),
   );
   runTimezoneTest(
     '1 year ago',
@@ -395,7 +395,7 @@ test('should return the date for "2024-03-09"', () => {
     '2024-03-09',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-03-09T00:00:00.000Z'),
+    new Date('2024-03-08T00:00:00.000Z'),
   );
   runTimezoneTest(
     '2024-03-09',
@@ -418,7 +418,7 @@ test('should return the current date for "Last day" with 
isEndDate true', () =>
     'Last day',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-03T00:00:00Z'),
+    new Date('2024-06-02T00:00:00Z'),
     true,
   );
   runTimezoneTest(
@@ -443,7 +443,7 @@ test('should return the current date for "Last week" with 
isEndDate true', () =>
     'Last week',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-03T00:00:00Z'),
+    new Date('2024-06-02T00:00:00Z'),
     true,
   );
   runTimezoneTest(
@@ -468,7 +468,7 @@ test('should return the current date for "Last quarter" 
with isEndDate true', ()
     'Last quarter',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-03T00:00:00Z'),
+    new Date('2024-06-02T00:00:00Z'),
     true,
   );
   runTimezoneTest(
@@ -493,7 +493,7 @@ test('should return the current date for "Last year" with 
isEndDate true', () =>
     'Last year',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-03T00:00:00Z'),
+    new Date('2024-06-02T00:00:00Z'),
     true,
   );
   runTimezoneTest(
@@ -518,14 +518,14 @@ test('should return the date for "previous calendar week" 
with isEndDate true',
     'previous calendar week',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-03T00:00:00Z'),
+    new Date('2024-06-03T20:00:00Z'),
     true,
   );
   runTimezoneTest(
     'previous calendar week',
     NOW_UTC_IN_PACIFIC,
     'Etc/GMT+8',
-    new Date('2024-06-03T08:00:00Z'),
+    new Date('2024-06-03T12:00:00Z'),
     true,
   );
 });
@@ -543,14 +543,14 @@ test('should return the date for "previous calendar 
month" with isEndDate true',
     'previous calendar month',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-06-01T00:00:00Z'),
+    new Date('2024-06-01T20:00:00Z'),
     true,
   );
   runTimezoneTest(
     'previous calendar month',
     NOW_UTC_IN_PACIFIC,
     'Etc/GMT+8',
-    new Date('2024-06-01T08:00:00Z'),
+    new Date('2024-06-01T12:00:00Z'),
     true,
   );
 });
@@ -568,14 +568,14 @@ test('should return the date for "previous calendar year" 
with isEndDate true',
     'previous calendar year',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-01-01T00:00:00Z'),
+    new Date('2024-01-01T20:00:00Z'),
     true,
   );
   runTimezoneTest(
     'previous calendar year',
     NOW_UTC_IN_PACIFIC,
     'Etc/GMT+8',
-    new Date('2024-01-01T08:00:00Z'),
+    new Date('2024-01-01T12:00:00Z'),
     true,
   );
 });
@@ -588,7 +588,7 @@ test('should return the date for "2024" with parts.length 
=== 1', () => {
     'Etc/GMT-2',
     new Date('2023-12-30T22:00:00.000Z'),
   );
-  runTimezoneTest('2024', NOW_IN_UTC, 'UTC', new Date('2024-01-01T00:00:00Z'));
+  runTimezoneTest('2024', NOW_IN_UTC, 'UTC', new Date('2023-12-31T00:00:00Z'));
   runTimezoneTest(
     '2024',
     NOW_UTC_IN_PACIFIC,
@@ -609,7 +609,7 @@ test('should return the date for "2024-03" with 
parts.length === 2', () => {
     '2024-03',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-03-01T00:00:00Z'),
+    new Date('2024-02-29T00:00:00Z'),
   );
   runTimezoneTest(
     '2024-03',
@@ -631,7 +631,7 @@ test('should return the date for "2024-03-06" with 
parts.length === 3', () => {
     '2024-03-06',
     NOW_IN_UTC,
     'UTC',
-    new Date('2024-03-06T00:00:00.000Z'),
+    new Date('2024-03-05T00:00:00.000Z'),
   );
   runTimezoneTest(
     '2024-03-06',

Reply via email to