From 52185415c3ba9e3c6308a465f6ac84c5bbbc07bb Mon Sep 17 00:00:00 2001 From: tsatke Date: Mon, 24 Jun 2024 13:00:35 +0200 Subject: [PATCH] fix compile error in read test --- ext2/tests/read.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ext2/tests/read.rs b/ext2/tests/read.rs index 4c8f2bc..d0f4e5b 100644 --- a/ext2/tests/read.rs +++ b/ext2/tests/read.rs @@ -1,9 +1,10 @@ -use ext2::{DirType, Ext2Fs, RegularFile, Type}; -use filesystem::MemoryBlockDevice; use std::env; use std::fs::File; use std::io::Read; +use ext2::{DirType, Ext2Fs, RegularFile, Type}; +use filesystem::MemoryBlockDevice; + #[test] fn test_list_directory() { do_test_list_directory(512); @@ -59,7 +60,7 @@ fn do_test_list_directory(sector_size: usize) { assert!(entries .iter() .find(|&entry| { - entry.inode().unwrap().get() == inode + entry.inode().get() == inode && entry.name().is_some_and(|n| n == name) && entry.typ() == Some(typ) })