void () { CommonCodeStyleSettings settings = getJavaSettings(); int old = settings.IF_BRACE_FORCE; try { settings.IF_BRACE_FORCE = CommonCodeStyleSettings.FORCE_BRACES_ALWAYS; doTest(); } finally { settings.IF_BRACE_FORCE = old; } }