Skip to content

Commit

Permalink
fix: fix doc test
Browse files Browse the repository at this point in the history
  • Loading branch information
RobWalt committed Dec 12, 2023
1 parent 7782937 commit 85828b4
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions geo/src/algorithm/stitch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ pub trait Stitch<T: GeoFloat> {
///
/// ```
/// use geo::Stitch;
/// use geo::{Coord, Triangle, Rect};
/// use geo::{Coord, Triangle, polygon};
///
/// let tri1 = Triangle::from([
/// Coord { x: 0.0, y: 0.0 },
Expand All @@ -68,7 +68,12 @@ pub trait Stitch<T: GeoFloat> {
/// // 4 coords + 1 duplicate for closed-ness
/// assert_eq!(poly.exterior().0.len(), 4 + 1);
///
/// let expected = Rect::new(Coord { x: 0.0, y: 0.0 }, Coord { x: 1.0, y: 1.0 }).to_polygon();
/// let expected = polygon![
/// Coord { x: 0.0, y: 1.0 },
/// Coord { x: 0.0, y: 0.0 },
/// Coord { x: 1.0, y: 0.0 },
/// Coord { x: 1.0, y: 1.0 },
/// ];
///
/// assert_eq!(poly, expected);
/// ```
Expand Down

0 comments on commit 85828b4

Please sign in to comment.