func testMultiTrailingClosure() {
var input = Parser("""
foo { _ in
}anotherClosure: { _ in
}
""")
let call = ExprSyntax.parse(from: &input)
let formatted = call.formatted()
assertStringsEqualWithDiff(formatted.description, """
foo { _ in
} anotherClosure: { _ in
}
""")
}
Produces:
failed - Actual output (+) differed from expected output (-):
–foo { _ in
–} anotherClosure: { _ in
+foo { _ in
+}anotherClosure: { _ in
}
ie. extra space after in
and no space after }
.