Parcourir la source

[3866] restore RW rights, aka #3866

Francis Dupont il y a 10 ans
Parent
commit
56c08641c3
1 fichiers modifiés avec 3 ajouts et 0 suppressions
  1. 3 0
      src/lib/util/tests/pid_file_unittest.cc

+ 3 - 0
src/lib/util/tests/pid_file_unittest.cc

@@ -190,6 +190,9 @@ TEST_F(PIDFileTest, pidWriteFail) {
 
     // Now try a write to the file, expecting an exception
     EXPECT_THROW(pid_file.write(10), PIDFileError);
+
+    // Don't forget to restore the write right for the next test
+    chmod(absolutePath(TESTNAME).c_str(), S_IRUSR | S_IWUSR);
 }
 
 /// @brief Test deleting a file that doesn't exist