diff --git a/src/tools/miri/tests/pass-dep/tokio/file-io.rs b/src/tools/miri/tests/pass-dep/tokio/file-io.rs index e4e923499703..7d05260c9551 100644 --- a/src/tools/miri/tests/pass-dep/tokio/file-io.rs +++ b/src/tools/miri/tests/pass-dep/tokio/file-io.rs @@ -21,6 +21,7 @@ async fn test_create_and_write() -> io::Result<()> { // Write 10 bytes to the file. file.write_all(b"some bytes").await?; + file.sync_all().await?; // tokio doesn't necessarily complete writes until you sync. assert_eq!(file.metadata().await.unwrap().len(), 10); remove_file(&path).unwrap();