}
+//===----------------------------------------------------------------------===//
+// Objective-C tests.
+//===----------------------------------------------------------------------===//
+
TEST_F(FormatTest, FormatForObjectiveCMethodDecls) {
verifyFormat("- (void)sendAction:(SEL)aSelector to:(BOOL)anObject;");
EXPECT_EQ("- (NSUInteger)indexOfObject:(id)anObject;",
verifyFormat("@ /*foo*/ interface");
}
+TEST_F(FormatTest, ObjCOneLiners) {
+ verifyFormat("@class Foo, Bar;");
+ verifyFormat("@synthesize dropArrowPosition = dropArrowPosition_;");
+ verifyFormat("@dynamic textColor;");
+
+ // FIXME: "getter=bar" should not be surround by spaces in @property.
+ verifyFormat("@property(assign, nonatomic) CGFloat hoverAlpha;");
+}
+
} // end namespace tooling
} // end namespace clang