Fix flaky gapfill test

The gapfill test assumed 1 day is always <= 24 hours which is not
true during DST switch leading to a failing test when run in that
time. This PR fixes the test to have reproducable output even
when run during DST switch.
This commit is contained in:
Sven Klemm 2020-03-09 12:02:31 +01:00 committed by Sven Klemm
parent ad97d266c0
commit 3ae9d6ca18
2 changed files with 4 additions and 4 deletions

View File

@ -2026,10 +2026,10 @@ GROUP BY 1;
-- time_bucket_gapfill with now() as start
SELECT
time_bucket_gapfill('1d'::interval,t)
time_bucket_gapfill('1h'::interval,t)
FROM (VALUES (now()),(now())) v(t)
WHERE
t >= now() AND t < now() - '1d'::interval
t >= now() AND t < now() - '1h'::interval
GROUP BY 1;
time_bucket_gapfill
---------------------

View File

@ -1239,10 +1239,10 @@ GROUP BY 1;
-- time_bucket_gapfill with now() as start
SELECT
time_bucket_gapfill('1d'::interval,t)
time_bucket_gapfill('1h'::interval,t)
FROM (VALUES (now()),(now())) v(t)
WHERE
t >= now() AND t < now() - '1d'::interval
t >= now() AND t < now() - '1h'::interval
GROUP BY 1;
-- time_bucket_gapfill with multiple constraints