summaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 4e630d5..9b726c8 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -24,4 +24,30 @@ mod tests {
assert!(false);
}
}
+
+ #[test]
+ fn tiff_height_test() {
+ tiff::ignore_warnings();
+ if let Some(t_handle) = tiff::open("../test.tif") {
+ let height = tiff::get_height(t_handle);
+ assert!(height > 0);
+ println!("{:?}", height);
+ tiff::close(t_handle);
+ } else {
+ assert!(false);
+ }
+ }
+
+ #[test]
+ fn tiff_width_test() {
+ tiff::ignore_warnings();
+ if let Some(t_handle) = tiff::open("../test.tif") {
+ let width = tiff::get_width(t_handle);
+ assert!(width > 0);
+ println!("{:?}", width);
+ tiff::close(t_handle);
+ } else {
+ assert!(false);
+ }
+ }
}