summaryrefslogtreecommitdiffstats
path: root/clang/unittests/Format/FormatTestObjC.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/unittests/Format/FormatTestObjC.cpp')
-rw-r--r--clang/unittests/Format/FormatTestObjC.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/clang/unittests/Format/FormatTestObjC.cpp b/clang/unittests/Format/FormatTestObjC.cpp
index b1e289d89b6..8fb93195881 100644
--- a/clang/unittests/Format/FormatTestObjC.cpp
+++ b/clang/unittests/Format/FormatTestObjC.cpp
@@ -114,7 +114,12 @@ TEST(FormatTestObjCStyle, DetectsObjCInHeaders) {
EXPECT_EQ(FormatStyle::LK_Cpp, Style->Language);
Style =
- getStyle("{}", "a.h", "none", "typedef NS_ENUM(NSInteger, Foo) {};\n");
+ getStyle("{}", "a.h", "none", "typedef NS_ENUM(int, Foo) {};\n");
+ ASSERT_TRUE((bool)Style);
+ EXPECT_EQ(FormatStyle::LK_ObjC, Style->Language);
+
+ Style = getStyle("{}", "a.h", "none",
+ "typedef NS_CLOSED_ENUM(int, Foo) {};\n");
ASSERT_TRUE((bool)Style);
EXPECT_EQ(FormatStyle::LK_ObjC, Style->Language);
OpenPOWER on IntegriCloud