diff --git a/clang/unittests/Format/FormatTestJS.cpp b/clang/unittests/Format/FormatTestJS.cpp --- a/clang/unittests/Format/FormatTestJS.cpp +++ b/clang/unittests/Format/FormatTestJS.cpp @@ -2359,5 +2359,12 @@ " static #staticPrivateMethod() {}\n"); } +TEST_F(FormatTestJS, DeclaredFields) { + verifyFormat("class Example {\n" + " declare pub: string;\n" + " declare private priv: string;\n" + "}\n"); +} + } // namespace format } // end namespace clang