mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-26 00:21:13 +00:00
"Undo" delete.
This commit is contained in:
parent
798c0fae71
commit
ba89c6399c
@ -284,9 +284,11 @@ TEST(FileTest, CloseError) {
|
||||
message + "\n");
|
||||
EXPECT_EQ(message, error.what());
|
||||
#else
|
||||
File other(".travis.yml", File::RDONLY);
|
||||
close(f->descriptor());
|
||||
// Closing file twice causes death on Windows.
|
||||
EXPECT_DEATH(f->close(), "");
|
||||
other.dup2(f->descriptor()); // "undo" close or delete will fail
|
||||
delete f;
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user