diff options
author | Andris Zeila <andris.zeila@zabbix.com> | 2021-11-11 14:12:56 +0300 |
---|---|---|
committer | Andris Zeila <andris.zeila@zabbix.com> | 2021-11-11 14:13:48 +0300 |
commit | b2302fe89ac4ef0a5be8f0c64ce375113191dbe1 (patch) | |
tree | 974849ab7f83308dc065e43edbb19eb5de78e7f5 /tests/libs/zbxtrends | |
parent | 8e9abed861fbdef5b3408dd4f430f9aeb00ca150 (diff) |
........S. [ZBXNEXT-2579] fixed week/year baseline calculations, added tests
Diffstat (limited to 'tests/libs/zbxtrends')
-rw-r--r-- | tests/libs/zbxtrends/zbx_baseline_get_data.yaml | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/tests/libs/zbxtrends/zbx_baseline_get_data.yaml b/tests/libs/zbxtrends/zbx_baseline_get_data.yaml index faa493525f0..2797dd83dff 100644 --- a/tests/libs/zbxtrends/zbx_baseline_get_data.yaml +++ b/tests/libs/zbxtrends/zbx_baseline_get_data.yaml @@ -180,4 +180,52 @@ out: end: 2019-12-31 23:00:00 +02:00 - start: 2018-01-01 0:00:00 +02:00 end: 2018-12-31 23:00:00 +02:00 +--- +test case: 2021-11-11 12:30:00 +02:00 baseline(1w:now/w, 2y, 0) +in: + timezone: :Europe/Riga + time: 2021-11-11 12:30:00 +02:00 + period: 1w:now/w + seasons: 2y + skip: 0 +out: + data: + - start: 2021-11-01 0:00:00 +02:00 + end: 2021-11-07 23:00:00 +02:00 + - start: 2020-10-26 0:00:00 +02:00 + end: 2020-11-01 23:00:00 +02:00 + - start: 2019-10-28 0:00:00 +02:00 + end: 2019-11-03 23:00:00 +02:00 +--- +test case: 2021-01-11 12:30:00 +02:00 baseline(1w:now/w, 2y, 0) +in: + timezone: :Europe/Riga + time: 2021-01-11 12:30:00 +02:00 + period: 1w:now/w + seasons: 2y + skip: 0 +out: + data: + - start: 2021-01-04 0:00:00 +02:00 + end: 2021-01-10 23:00:00 +02:00 + - start: 2019-12-30 0:00:00 +02:00 + end: 2020-01-05 23:00:00 +02:00 + - start: 2018-12-31 0:00:00 +02:00 + end: 2019-01-06 23:00:00 +02:00 +--- +test case: 2021-01-10 12:30:00 +02:00 baseline(1w:now/w, 2y, 0) +in: + timezone: :Europe/Riga + time: 2021-01-10 12:30:00 +02:00 + period: 1w:now/w + seasons: 2y + skip: 0 +out: + data: + - start: 2020-12-28 0:00:00 +02:00 + end: 2021-01-03 23:00:00 +02:00 + - start: 2019-12-23 0:00:00 +02:00 + end: 2019-12-29 23:00:00 +02:00 + - start: 2018-12-24 0:00:00 +02:00 + end: 2018-12-30 23:00:00 +02:00 ... |