1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 03:27:44 +00:00

Merge pull request #7622 from blyxxyz/flush-bufwriters

Flush `BufWriter`s, clean up error reporting
This commit is contained in:
Terts Diepraam 2025-04-08 20:52:51 +02:00 committed by GitHub
commit 8040305715
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
19 changed files with 173 additions and 63 deletions

View file

@ -4843,3 +4843,13 @@ fn test_child_when_run_with_stderr_to_stdout() {
.fails()
.stdout_only(expected_stdout);
}
#[cfg(target_os = "linux")]
#[test]
fn test_failed_write_is_reported() {
new_ucmd!()
.pipe_in("hello")
.set_stdout(std::fs::File::create("/dev/full").unwrap())
.fails()
.stderr_is("tail: No space left on device\n");
}