Skip to content

Commit bb8261b

Browse files
[MemProf] Make Test work with Internal Shell
There is one test that uses a subshell to generate a long path name. Replace it with a python invocation and a readfile substitution. This helps move compiler-rt over to lit's internal shell. Reviewers: fmayer, snehasish, teresajohnson Reviewed By: fmayer, teresajohnson Pull Request: llvm#165146
1 parent 841d85f commit bb8261b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

compiler-rt/test/memprof/TestCases/log_path_test.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@
1818
// RUN: %env_memprof_opts=print_text=true:log_path=/dev/null/INVALID not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK-BAD-DIR --dump-input=always
1919

2020
// Too long log_path.
21-
// RUN: %env_memprof_opts=print_text=true:log_path=`for((i=0;i<10000;i++)); do echo -n $i; done` \
21+
// RUN: %python -c "for i in range(0, 10000): print(i, end='')" > %t.long_log_path
22+
// RUN: %env_memprof_opts=print_text=true:log_path=%{readfile:%t.long_log_path} \
2223
// RUN: not %run %t 2>&1 | FileCheck %s --check-prefix=CHECK-LONG --dump-input=always
2324

2425
// Specifying the log name via the __memprof_profile_filename variable.

0 commit comments

Comments
 (0)