-
Notifications
You must be signed in to change notification settings - Fork 654
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test statfs_call()
fails on macOS because statfs()
and statvfs()
report different number of i-nodes
#2411
Comments
statfs_call()
fails on macOS as statfs()
and statvfs()
report different number of i-nodesstatfs_call()
fails on macOS because statfs()
and statvfs()
report different number of i-nodes
That's weird. That line checks the total number of inodes on the file system. That should never change, at least on a traditional file system like UFS. But apparently it can change here. I wonder if it was /dev or one of the real file systems? |
That test checks 4 paths, according to the output of #[test]
fn statfs_call() {
check_statfs("/tmp"); // refers to the file system mounted at `/`
check_statfs("/dev"); // refers to the file system mounted at `/dev`
check_statfs("/run"); // will be skipped since this directory does not exist
check_statfs("/"); // refers to the file system mounted at `/`
}
So yes, it indeed checks |
I think we should just remove the check for number of inodes. After all, our goal isn't to test statvfs itself, just to test that our bindings to it are doing the right thing. |
Yeah, let me remove it. |
Sometimes, test
statfs_call()
fails in our macOS CI, e.g., this one:It failed in this line, where
statfs()
andstatvfs()
were reporting different number of i-nodes.The text was updated successfully, but these errors were encountered: