void () { doTextTest("java", """ class Foo { void foo() { for(;;)<caret> foo(); } }""", """ class Foo { void foo() { for(;;) <caret> foo(); } }"""); doTextTest("java", """ class Foo { void foo() { for(;;) {<caret> foo();} } }""", """ class Foo { void foo() { for(;;) { <caret> foo();} } }"""); doTextTest("java", """ class Foo { void foo() { for(;;) <caret>{ foo();} } }""", """ class Foo { void foo() { for(;;)\s <caret>{ foo();} } }"""); doTextTest("java", """ class Foo { void foo() { for(;<caret>;) { foo();} } }""", """ class Foo { void foo() { for(; <caret>;) { foo();} } }"""); doTextTest("java", """ class Foo { void foo() { for(;;)<caret> } }""", """ class Foo { void foo() { for(;;) <caret> } }"""); }