mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 19:52:54 +01:00
e659840bcd
The %T lit expansion expands to a common directory shared between all the tests in the same directory, which is unexpected and unintuitive, and more importantly, it's been a source of subtle race conditions and flaky tests. In https://reviews.llvm.org/D35396, it was agreed that it would be best to simply ban %T and only keep %t, which is unique to each test. When a test needs a temporary directory, it can just create one using mkdir %t. This patch removes %T in llvm. Differential Revision: https://reviews.llvm.org/D36495 llvm-svn: 310953
22 lines
808 B
Plaintext
22 lines
808 B
Plaintext
REQUIRES: can-execute
|
|
|
|
This tests that we abstract two peculiarities of unix in can_execute:
|
|
|
|
* Directories are executable, but we don't want to try to execute them.
|
|
* For shell scripts, we also need to be able to read them.
|
|
|
|
The PATH is constructed such that 'not' will first find a directory named
|
|
TestProg, then a file with executable bit but not readable and finally a
|
|
shell script which always returns false, which is what it actually tries to
|
|
execute.
|
|
|
|
If we want, it is probably OK to change the semantics of can_execute and this
|
|
test, but for now this test serves as a reminder to audit all the callers if
|
|
we do that.
|
|
|
|
RUN: rm -rf %t && mkdir -p %t
|
|
RUN: cp -f %S/Inputs/TestProg/TestProg %t/TestProg
|
|
RUN: chmod 111 %t/TestProg
|
|
RUN: export PATH=%S/Inputs:%t:%S/Inputs/TestProg:$PATH
|
|
RUN: not TestProg
|