Skip to content

Commit

Permalink
💚 Fix broken doctest due to mismatched Array type
Browse files Browse the repository at this point in the history
Update docstring in src/lib.rs to check for an Array3 output from the read_geotiff function. Patches bca4c18.
  • Loading branch information
weiji14 committed Jul 8, 2024
1 parent 5677144 commit bd59c1c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
//!
//! use bytes::Bytes;
//! use cog3pio::io::geotiff::read_geotiff;
//! use ndarray::Array2;
//! use ndarray::Array3;
//! use object_store::path::Path;
//! use object_store::{parse_url, GetResult, ObjectStore};
//! use tokio;
Expand All @@ -38,9 +38,9 @@
//! Cursor::new(bytes)
//! };
//!
//! let arr: Array2<f32> = read_geotiff(stream).unwrap();
//! assert_eq!(arr.dim(), (549, 549));
//! assert_eq!(arr[[500, 500]], 0.13482364);
//! let arr: Array3<f32> = read_geotiff(stream).unwrap();
//! assert_eq!(arr.dim(), (1, 549, 549));
//! assert_eq!(arr[[0, 500, 500]], 0.13482364);
//! }
//! ```

Expand Down

0 comments on commit bd59c1c

Please sign in to comment.