diff options
author | Fredrik Meringdal <fmeringdal@hotmail.com> | 2020-10-24 15:06:32 +0200 |
---|---|---|
committer | Fredrik Meringdal <fmeringdal@hotmail.com> | 2020-10-24 15:06:32 +0200 |
commit | 3545c981ac92e277574b29ef4de03aa2f2cc62c3 (patch) | |
tree | 8802c5f17dd77d3e8fb815874f7964af38f54248 /tests | |
parent | a4c2f576ad0462b3bc8989512a608557c9287723 (diff) | |
download | rust_rrule-3545c981ac92e277574b29ef4de03aa2f2cc62c3.zip |
removed unused code
Diffstat (limited to 'tests')
-rw-r--r-- | tests/rrule.rs | 70 |
1 files changed, 63 insertions, 7 deletions
diff --git a/tests/rrule.rs b/tests/rrule.rs index 65aed6c..6365abc 100644 --- a/tests/rrule.rs +++ b/tests/rrule.rs @@ -40,7 +40,27 @@ mod test { #[test] fn yearly() { - let options = ParsedOptions::new(Frequenzy::YEARLY, &ymd_hms(1997, 9, 2, 9, 0, 0)).count(3); + let options = ParsedOptions { + freq: Frequenzy::YEARLY, + count: Some(3), + bymonth: vec![9], + dtstart: ymd_hms(1997, 9, 2, 9, 0, 0), + byweekday: vec![], + byhour: vec![9], + bysetpos: vec![], + byweekno: vec![], + byminute: vec![0], + bysecond: vec![0], + byyearday: vec![], + bymonthday: vec![2], + bynweekday: vec![], + bynmonthday: vec![], + until: None, + wkst: 0, + tzid: None, + interval: 1, + byeaster: None, + }; test_recurring( options, &vec![ @@ -53,9 +73,27 @@ mod test { #[test] fn yearly_interval() { - let options = ParsedOptions::new(Frequenzy::YEARLY, &ymd_hms(1997, 9, 2, 9, 0, 0)) - .count(3) - .interval(2); + let options = ParsedOptions { + freq: Frequenzy::YEARLY, + count: Some(3), + bymonth: vec![9], + dtstart: ymd_hms(1997, 9, 2, 9, 0, 0), + byweekday: vec![], + byhour: vec![9], + bysetpos: vec![], + byweekno: vec![], + byminute: vec![0], + bysecond: vec![0], + byyearday: vec![], + bymonthday: vec![2], + bynweekday: vec![], + bynmonthday: vec![], + until: None, + wkst: 0, + tzid: None, + interval: 2, + byeaster: None, + }; test_recurring( options, &vec![ @@ -68,9 +106,27 @@ mod test { #[test] fn yearly_interval_large() { - let options = ParsedOptions::new(Frequenzy::YEARLY, &ymd_hms(1997, 9, 2, 9, 0, 0)) - .count(3) - .interval(40); + let options = ParsedOptions { + freq: Frequenzy::YEARLY, + count: Some(3), + bymonth: vec![9], + dtstart: ymd_hms(1997, 9, 2, 9, 0, 0), + byweekday: vec![], + byhour: vec![9], + bysetpos: vec![], + byweekno: vec![], + byminute: vec![0], + bysecond: vec![0], + byyearday: vec![], + bymonthday: vec![2], + bynweekday: vec![], + bynmonthday: vec![], + until: None, + wkst: 0, + tzid: None, + interval: 40, + byeaster: None, + }; test_recurring( options, &vec![ |