Author: sammccall Date: Mon Jan 8 07:49:40 2018 New Revision: 322001 URL: http://llvm.org/viewvc/llvm-project?rev=322001&view=rev Log: Avoid assumption that lit tests are writable. NFC
Modified: clang-tools-extra/trunk/test/clang-apply-replacements/crlf.cpp clang-tools-extra/trunk/test/clang-move/move-function.cpp clang-tools-extra/trunk/test/clang-move/no-move-macro-helpers.cpp Modified: clang-tools-extra/trunk/test/clang-apply-replacements/crlf.cpp URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-apply-replacements/crlf.cpp?rev=322001&r1=322000&r2=322001&view=diff ============================================================================== --- clang-tools-extra/trunk/test/clang-apply-replacements/crlf.cpp (original) +++ clang-tools-extra/trunk/test/clang-apply-replacements/crlf.cpp Mon Jan 8 07:49:40 2018 @@ -1,5 +1,5 @@ // RUN: mkdir -p %T/Inputs/crlf -// RUN: cp %S/Inputs/crlf/crlf.cpp %T/Inputs/crlf/crlf.cpp +// RUN: cat %S/Inputs/crlf/crlf.cpp > %T/Inputs/crlf/crlf.cpp // RUN: sed "s#\$(path)#%/T/Inputs/crlf#" %S/Inputs/crlf/file1.yaml > %T/Inputs/crlf/file1.yaml // RUN: clang-apply-replacements %T/Inputs/crlf // RUN: diff %T/Inputs/crlf/crlf.cpp %S/Inputs/crlf/crlf.cpp.expected Modified: clang-tools-extra/trunk/test/clang-move/move-function.cpp URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-move/move-function.cpp?rev=322001&r1=322000&r2=322001&view=diff ============================================================================== --- clang-tools-extra/trunk/test/clang-move/move-function.cpp (original) +++ clang-tools-extra/trunk/test/clang-move/move-function.cpp Mon Jan 8 07:49:40 2018 @@ -1,5 +1,6 @@ // RUN: mkdir -p %T/move-function -// RUN: cp %S/Inputs/function_test* %T/move-function +// RUN: cat %S/Inputs/function_test.h > %T/move-function/function_test.h +// RUN: cat %S/Inputs/function_test.cpp > %T/move-function/function_test.cpp // RUN: cd %T/move-function // RUN: clang-move -names="g" -new_header=%T/move-function/new_function_test.h -old_header=../move-function/function_test.h %T/move-function/function_test.cpp -- // RUN: FileCheck -input-file=%T/move-function/new_function_test.h -check-prefix=CHECK-NEW-TEST-H-CASE1 %s @@ -39,12 +40,14 @@ // CHECK-NEW-TEST-CPP-CASE3: {{[[:space:]]+}} // CHECK-NEW-TEST-CPP-CASE3: void f() {} // -// RUN: cp %S/Inputs/function_test* %T/move-function +// RUN: cat %S/Inputs/function_test.h > %T/move-function/function_test.h +// RUN: cat %S/Inputs/function_test.cpp > %T/move-function/function_test.cpp // RUN: clang-move -names="A::f" -new_header=%T/move-function/new_function_test.h -new_cc=%T/move-function/new_function_test.cpp -old_header=../move-function/function_test.h -old_cc=../move-function/function_test.cpp %T/move-function/function_test.cpp -dump_result -- | FileCheck %s -check-prefix=CHECK-EMPTY // // CHECK-EMPTY: [{{[[:space:]]*}}] // -// RUN: cp %S/Inputs/function_test* %T/move-function +// RUN: cat %S/Inputs/function_test.h > %T/move-function/function_test.h +// RUN: cat %S/Inputs/function_test.cpp > %T/move-function/function_test.cpp // RUN: clang-move -names="f,A" -new_header=%T/move-function/new_function_test.h -new_cc=%T/move-function/new_function_test.cpp -old_header=../move-function/function_test.h -old_cc=../move-function/function_test.cpp %T/move-function/function_test.cpp -- // RUN: FileCheck -input-file=%T/move-function/new_function_test.h -check-prefix=CHECK-NEW-TEST-H-CASE4 %s // RUN: FileCheck -input-file=%T/move-function/new_function_test.cpp -check-prefix=CHECK-NEW-TEST-CPP-CASE4 %s Modified: clang-tools-extra/trunk/test/clang-move/no-move-macro-helpers.cpp URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-move/no-move-macro-helpers.cpp?rev=322001&r1=322000&r2=322001&view=diff ============================================================================== --- clang-tools-extra/trunk/test/clang-move/no-move-macro-helpers.cpp (original) +++ clang-tools-extra/trunk/test/clang-move/no-move-macro-helpers.cpp Mon Jan 8 07:49:40 2018 @@ -1,6 +1,6 @@ // RUN: mkdir -p %T/no-move-macro-helper -// RUN: cp %S/Inputs/macro_helper_test.h %T/no-move-macro-helper/macro_helper_test.h -// RUN: cp %S/Inputs/macro_helper_test.cpp %T/no-move-macro-helper/macro_helper_test.cpp +// RUN: cat %S/Inputs/macro_helper_test.h > %T/no-move-macro-helper/macro_helper_test.h +// RUN: cat %S/Inputs/macro_helper_test.cpp > %T/no-move-macro-helper/macro_helper_test.cpp // RUN: cd %T/no-move-macro-helper // // ----------------------------------------------------------------------------- @@ -24,8 +24,8 @@ // ----------------------------------------------------------------------------- // Test moving all. // ----------------------------------------------------------------------------- -// RUN: cp %S/Inputs/macro_helper_test.h %T/no-move-macro-helper/macro_helper_test.h -// RUN: cp %S/Inputs/macro_helper_test.cpp %T/no-move-macro-helper/macro_helper_test.cpp +// RUN: cat %S/Inputs/macro_helper_test.h > %T/no-move-macro-helper/macro_helper_test.h +// RUN: cat %S/Inputs/macro_helper_test.cpp > %T/no-move-macro-helper/macro_helper_test.cpp // RUN: clang-move -names="A, f1" -new_cc=%T/no-move-macro-helper/new_test.cpp -new_header=%T/no-move-macro-helper/new_test.h -old_cc=%T/no-move-macro-helper/macro_helper_test.cpp -old_header=%T/no-move-macro-helper/macro_helper_test.h %T/no-move-macro-helper/macro_helper_test.cpp -- -std=c++11 // // RUN: FileCheck -input-file=%T/no-move-macro-helper/new_test.h -check-prefix=CHECK-NEW-TEST-CASE2-H %s _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits