libstdc++: Clear up directories created by tests
authorJonathan Wakely <jwakely@redhat.com>
Tue, 9 Feb 2021 16:53:56 +0000 (16:53 +0000)
committerJonathan Wakely <jwakely@redhat.com>
Tue, 9 Feb 2021 16:54:41 +0000 (16:54 +0000)
libstdc++-v3/ChangeLog:

* testsuite/27_io/filesystem/operations/remove_all.cc: Remove
test directory after making it writable again.
* testsuite/experimental/filesystem/operations/remove_all.cc:
Likewise.

libstdc++-v3/testsuite/27_io/filesystem/operations/remove_all.cc
libstdc++-v3/testsuite/experimental/filesystem/operations/remove_all.cc

index ee16d67debd20593cda7c3d51c79ee443b9c9ed0..986a8dfb2aef3b3d70549378a3b4ad870b1782b3 100644 (file)
@@ -171,6 +171,8 @@ test04()
   }
 
   fs::permissions(dir, fs::perms::owner_write, fs::perm_options::add);
+  fs::remove_all(dir, ec);
+  f.path.clear();
 #endif
 }
 
index 9aca6c8af67b4dad1acfb37de41116f07fc9e359..87fd2dde41d1dad36664f6abe4036c6fd3c26c17 100644 (file)
@@ -137,6 +137,8 @@ test04()
   }
 
   fs::permissions(dir, fs::perms::owner_write|fs::perms::add_perms);
+  fs::remove_all(dir, ec);
+  f.path.clear();
 #endif
 }