Skip to content

Commit

Permalink
add test with leading whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
kylebarron committed Oct 7, 2024
1 parent 3aaf200 commit 56a7fcd
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/infer_type.rs
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,19 @@ mod test {
);
}

#[test]
fn test_with_leading_whitespace() {
assert_eq!(
infer_type(" POINT (10 20.1)").unwrap(),
(GeometryType::Point, Some(Dimension::XY))
);

assert_eq!(
infer_type("POINT EMPTY").unwrap(),
(GeometryType::Point, None)
);
}

#[test]
fn lowercase_point() {
assert_eq!(
Expand Down

0 comments on commit 56a7fcd

Please sign in to comment.