Changeset View
Changeset View
Standalone View
Standalone View
unittests/Format/FormatTestJava.cpp
Show First 20 Lines • Show All 211 Lines • ▼ Show 20 Lines | verifyFormat("@Override\n" | ||||
"public Map<String, ?> getAll() {\n}"); | "public Map<String, ?> getAll() {\n}"); | ||||
verifyFormat("public <R> ArrayList<R> get() {\n}"); | verifyFormat("public <R> ArrayList<R> get() {\n}"); | ||||
verifyFormat("protected <R> ArrayList<R> get() {\n}"); | verifyFormat("protected <R> ArrayList<R> get() {\n}"); | ||||
verifyFormat("private <R> ArrayList<R> get() {\n}"); | verifyFormat("private <R> ArrayList<R> get() {\n}"); | ||||
verifyFormat("public static <R> ArrayList<R> get() {\n}"); | verifyFormat("public static <R> ArrayList<R> get() {\n}"); | ||||
verifyFormat("<T extends B> T getInstance(Class<T> type);"); | verifyFormat("<T extends B> T getInstance(Class<T> type);"); | ||||
verifyFormat("Function<F, ? extends T> function;"); | verifyFormat("Function<F, ? extends T> function;"); | ||||
verifyFormat("private Foo<X, Y>[] foos;"); | |||||
verifyFormat("Foo<X, Y>[] foos = this.foos;"); | |||||
} | } | ||||
TEST_F(FormatTestJava, StringConcatenation) { | TEST_F(FormatTestJava, StringConcatenation) { | ||||
verifyFormat("String someString = \"abc\"\n" | verifyFormat("String someString = \"abc\"\n" | ||||
" + \"cde\";"); | " + \"cde\";"); | ||||
} | } | ||||
TEST_F(FormatTestJava, TryCatchFinally) { | TEST_F(FormatTestJava, TryCatchFinally) { | ||||
▲ Show 20 Lines • Show All 49 Lines • Show Last 20 Lines |