test/cronline_test.rb in openwferu-0.9.15 vs test/cronline_test.rb in openwferu-0.9.16
- old
+ new
@@ -36,16 +36,25 @@
assert \
cl.to_array == array
end
- def test_cron_line_0
- do_cltest "* * * * *", [ nil, nil, nil, nil, nil ]
- do_cltest "10-12 * * * *", [ [10, 11, 12], nil, nil, nil, nil ]
- do_cltest "* * * * sun,mon", [ nil, nil, nil, nil, [7, 1] ]
- do_cltest "* * * * mon-wed", [ nil, nil, nil, nil, [1, 2, 3] ]
+ def test_0
- #do_cltest "* * * * sun,mon-tue", [ nil, nil, nil, nil, [7, 1, 2] ]
- #do_cltest "* * * * 7-1", [ nil, nil, nil, nil, [7, 1, 2] ]
+ do_cltest "* * * * *", [ [0], nil, nil, nil, nil, nil ]
+ do_cltest "10-12 * * * *", [ [0], [10, 11, 12], nil, nil, nil, nil ]
+ do_cltest "* * * * sun,mon", [ [0], nil, nil, nil, nil, [7, 1] ]
+ do_cltest "* * * * mon-wed", [ [0], nil, nil, nil, nil, [1, 2, 3] ]
+
+ #do_cltest "* * * * sun,mon-tue", [ [0], nil, nil, nil, nil, [7, 1, 2] ]
+ #do_cltest "* * * * 7-1", [ [0], nil, nil, nil, nil, [7, 1, 2] ]
+ end
+
+ def test_1
+
+ do_cltest "* * * * * *", [ nil, nil, nil, nil, nil, nil ]
+ do_cltest "1 * * * * *", [ [1], nil, nil, nil, nil, nil ]
+ do_cltest "7 10-12 * * * *", [ [7], [10, 11, 12], nil, nil, nil, nil ]
+ do_cltest "1-5 * * * * *", [ [1,2,3,4,5], nil, nil, nil, nil, nil ]
end
end