From ba6b32d1ce34dacaca5df11dfb5e460b1445914a Mon Sep 17 00:00:00 2001 From: Edwin Vane Date: Tue, 18 Jun 2013 15:44:58 +0000 Subject: cpp11-migrate: Transforms honour header modification flag Transforms will now make changes to headers if header modifications have been enabled. FIXME: Only UseNullptr contains a cursory header modification test. Other transforms should have them too. llvm-svn: 184197 --- clang-tools-extra/test/cpp11-migrate/UseNullptr/basic.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'clang-tools-extra/test/cpp11-migrate/UseNullptr/basic.cpp') diff --git a/clang-tools-extra/test/cpp11-migrate/UseNullptr/basic.cpp b/clang-tools-extra/test/cpp11-migrate/UseNullptr/basic.cpp index 03606f6acd3..9057c1a17d7 100644 --- a/clang-tools-extra/test/cpp11-migrate/UseNullptr/basic.cpp +++ b/clang-tools-extra/test/cpp11-migrate/UseNullptr/basic.cpp @@ -1,8 +1,13 @@ +// RUN: mkdir -p %T/Inputs // RUN: grep -Ev "// *[A-Z-]+:" %s > %t.cpp -// RUN: grep -Ev "// *[A-Z-]+:" %S/Inputs/basic.h > %T/basic.h -// RUN: cpp11-migrate -use-nullptr %t.cpp -- -std=c++98 -I %S +// RUN: grep -Ev "// *[A-Z-]+:" %S/Inputs/basic.h > %T/Inputs/basic.h +// RUN: cpp11-migrate -use-nullptr %t.cpp -- -std=c++98 -I %T -Wno-non-literal-null-conversion // RUN: FileCheck -input-file=%t.cpp %s -// RUN: FileCheck -input-file=%T/basic.h %S/Inputs/basic.h +// RUN: FileCheck -input-file=%T/Inputs/basic.h %S/Inputs/basic.h +// RUN: grep -Ev "// *[A-Z-]+:" %s > %t.cpp +// RUN: grep -Ev "// *[A-Z-]+:" %S/Inputs/basic.h > %T/Inputs/basic.h +// RUN: cpp11-migrate -headers -include=%T -use-nullptr %t.cpp -- -std=c++98 -I %T -Wno-non-literal-null-conversion +// RUN: FileCheck -check-prefix=HEADERS -input-file=%T/Inputs/basic.h %S/Inputs/basic.h #include "Inputs/basic.h" -- cgit v1.2.3