mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-02-25 03:44:52 +00:00
Cron.pm: wip
git-svn-id: https://svn.fhem.de/fhem/trunk@27889 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
03de270697
commit
4dc36e2cd5
@ -61,7 +61,8 @@ my $test = [
|
||||
[q(handle '$cron_text'), '0 0 * * 1-5,6', qr(^$), 20230101000000, 20230102000000, 20230103000000, 20230104000000, 20230105000000, 20230106000000, 20230107000000 ],
|
||||
[q(handle '$cron_text'), '0 0 8 * 1-5,6', qr(^$), 20230101000000, 20230102000000, 20230103000000, 20230104000000, 20230105000000, 20230106000000, 20230107000000, 20230108000000 ],
|
||||
[q(handle '$cron_text'), '0 0 2-8 * &1-5,6', qr(^$), 20230101000000, 20230102000000, 20230103000000, 20230104000000, 20230105000000, 20230106000000, 20230107000000, 20230114000000 ],
|
||||
[q(handle '$cron_text'), '0 0 2-8 * 1#1', qr(^$), 20230101000000 ],
|
||||
# positional
|
||||
[q(handle '$cron_text'), '0 0 * * 4#l', qr(^$), 20230101000000, 20230126000000, 20230223000000, 20230330000000, 20230427000000, 20230525000000, 20230629000000 ],
|
||||
|
||||
# time series
|
||||
[q(Timeseries '$cron_text'), '0 12 3,4,5 2 0,2,3,4', qr(^$), 20230102150000, 20230201120000, 20230202120000, 20230203120000, 20230204120000],
|
||||
|
@ -15,7 +15,8 @@ my $test = [
|
||||
#[q(Timeseries '$cron_text'), '0 12 3,4,5 2 0,2,3,4', qr(^$), 20230102150000, 20230201120000, 20230202120000, 20230203120000, 20230204120000],
|
||||
#[q(Feb-29 & Sunday '$cron_text'), '0 12 29 2 &7', qr(^$), 20230102150000, 20320229120000, sub {20600229120000}->()],
|
||||
#[q(accept '$cron_text'), '1-5 * * * *', qr(^$), sub {my @r = (20230101000000); for my $h (0..23) {for my $m (1..5) {push @r, sprintf('20230101%02d%02d00', $h, $m)}}; @r}->()],
|
||||
[q(handle '$cron_text'), '0 0 2-8 * &1-5,6', qr(^$), 20230101000000, 20230102000000, 20230103000000, 20230104000000, 20230105000000, 20230106000000, 20230107000000, 20230114000000 ],
|
||||
#[q(handle '$cron_text'), '0 0 2-8 * &1-5,6', qr(^$), 20230101000000, 20230102000000, 20230103000000, 20230104000000, 20230105000000, 20230106000000, 20230107000000, 20230114000000 ],
|
||||
[q(handle '$cron_text'), '0 0 * * 4#l', qr(^$), 20230101000000, 20230126000000, 20230223000000, 20230330000000, 20230427000000, 20230525000000, 20230629000000 ],
|
||||
];
|
||||
|
||||
foreach my $t (@$test) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user