[PATCH] D70854: [Clang] In tests, do not always assume others permissions are set

Alexandre Ganea via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 11 10:11:26 PST 2019


aganea updated this revision to Diff 233402.
aganea added a comment.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Ensure the access-rights commands (setfacl and chmod) won't fail the tests if the user doesn't have the appropriate rights to change permissions.
Added `llvm/test/Other/umask.ll` because it was also failing.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D70854/new/

https://reviews.llvm.org/D70854

Files:
  clang/test/Misc/permissions.cpp
  llvm/test/Other/umask.ll


Index: llvm/test/Other/umask.ll
===================================================================
--- llvm/test/Other/umask.ll
+++ llvm/test/Other/umask.ll
@@ -1,6 +1,9 @@
 ; REQUIRES: shell
 ; XFAIL: windows-gnu
 
+; RUN: setfacl -bn %T || true
+; RUN: chmod -R o+rx %T || true
+
 ; RUN: umask 000
 ; RUN: rm -f %t.000
 ; RUN: llvm-as %s -o %t.000
Index: clang/test/Misc/permissions.cpp
===================================================================
--- clang/test/Misc/permissions.cpp
+++ clang/test/Misc/permissions.cpp
@@ -1,5 +1,8 @@
 // REQUIRES: shell
 
+// RUN: setfacl -bn %T || true
+// RUN: chmod -R o+rx %T || true
+
 // RUN: umask 000
 // RUN: %clang_cc1 -emit-llvm-bc %s -o %t
 // RUN: ls -l %t | FileCheck --check-prefix=CHECK000 %s


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D70854.233402.patch
Type: text/x-patch
Size: 755 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20191211/bd6c493f/attachment-0001.bin>


More information about the cfe-commits mailing list