test: update test in Timestamp::start_to_chorno
This commit is contained in:
parent
c4d9aa4c51
commit
20a46b132e
1 changed files with 3 additions and 0 deletions
|
|
@ -68,6 +68,9 @@ impl Timestamp {
|
|||
///
|
||||
/// let ts = Org::parse("[2003-09-16 Tue 09:39-10:39]").first_node::<Timestamp>().unwrap();
|
||||
/// assert_eq!(ts.start_to_chrono().unwrap(), "2003-09-16T09:39:00".parse::<NaiveDateTime>().unwrap());
|
||||
///
|
||||
/// let ts = Org::parse("[2003-13-00 Tue 09:39-10:39]").first_node::<Timestamp>().unwrap();
|
||||
/// assert!(ts.start_to_chrono().is_none());
|
||||
/// ```
|
||||
#[cfg(feature = "chrono")]
|
||||
pub fn start_to_chrono(&self) -> Option<chrono::NaiveDateTime> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue