mirror of
https://github.com/sharkdp/fd
synced 2024-10-04 14:59:15 +00:00
Use .write_all
This commit is contained in:
parent
3066445e6b
commit
289d6443a7
|
@ -49,7 +49,7 @@ fn get_test_env_with_abs_path(dirs: &[&'static str], files: &[&'static str]) ->
|
|||
fn create_file_with_size<P: AsRef<Path>>(path: P, size_in_bytes: usize) {
|
||||
let content = "#".repeat(size_in_bytes);
|
||||
let mut f = fs::File::create::<P>(path).unwrap();
|
||||
f.write(content.as_bytes()).unwrap();
|
||||
f.write_all(content.as_bytes()).unwrap();
|
||||
}
|
||||
|
||||
/// Simple tests
|
||||
|
|
Loading…
Reference in a new issue