void () { for (String innerCallText : List.of("noArg()", "singleArg(1)", "singleArg(new Object())", "singleArg {}", "singleArg([:])", "doubleArg([:]) {}", "doubleArg(1, 2)", "doubleArg([], {})", "doubleArg(new Object[0]) {}", "doubleArg(new Object[0], {})", "varArg(1, 2, 3)", "varArg(1, 2d, '')", "varArg(new Object(), [], {}, a: 1, 2d, [:], '')")) { for (String callText : List.of("singleArg {<caret>" + innerCallText + "}", "doubleArg([:]) {<caret>" + innerCallText + "}", "doubleArg([], {<caret>" + innerCallText + "})", "doubleArg(new Object[0], {<caret>" + innerCallText + "})", "varArg(new Object(), [], {<caret>" + innerCallText + "}, a: 1, 2d, [:], '')")) { for (String s : List.of("builder.root {" + callText + "}", "builder.root(a: 1, b: 2) {" + callText + "}", "builder.root([1, 2, 3, 4]) {" + callText + "}", "builder.root([] as Integer[], {" + callText + "})")) { doTest(s); } } } }