From 2964749cfad609d4e191af77162db79d8e02fcf6 Mon Sep 17 00:00:00 2001 From: Daniel Jasper Date: Tue, 5 May 2015 08:12:50 +0000 Subject: clang-format: [JS] Do not collapse short interfaces. Patch by Martin Probst. llvm-svn: 236485 --- clang/unittests/Format/FormatTestJS.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'clang/unittests/Format/FormatTestJS.cpp') diff --git a/clang/unittests/Format/FormatTestJS.cpp b/clang/unittests/Format/FormatTestJS.cpp index a7d8dd3effa..0c36dce93dd 100644 --- a/clang/unittests/Format/FormatTestJS.cpp +++ b/clang/unittests/Format/FormatTestJS.cpp @@ -547,6 +547,12 @@ TEST_F(FormatTestJS, ClassDeclarations) { verifyFormat("class C extends p.P implements i.I {}"); } +TEST_F(FormatTestJS, InterfaceDeclarations) { + verifyFormat("interface I {\n" + " x: string;\n" + "}"); +} + TEST_F(FormatTestJS, MetadataAnnotations) { verifyFormat("@A\nclass C {\n}"); verifyFormat("@A({arg: 'value'})\nclass C {\n}"); -- cgit v1.2.3