Add test cases for go closing brace indentation

This commit is contained in:
John Isom 2020-07-26 20:28:33 -06:00
parent 902f2831d8
commit 0439128007
12 changed files with 130 additions and 0 deletions

View File

@ -0,0 +1 @@
c<ret>

View File

@ -0,0 +1,12 @@
func foo(x int) int {%( )}
func foo(x int) int {%( )
}
func foo(x int) int {%( )bar()}
func foo(x int) int {%( )bar()
}
func foo(x int) int {
bar()%( )}

View File

@ -0,0 +1,17 @@
func foo(x int) int {
}
func foo(x int) int {
}
func foo(x int) int {
bar()}
func foo(x int) int {
bar()
}
func foo(x int) int {
bar()
}

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/filetype/go.kak"
set buffer filetype go

View File

@ -0,0 +1 @@
c<ret>

View File

@ -0,0 +1,25 @@
{%( )}
{%( )
}
{%( )bar()}
{%( )bar()
}
{
bar()%( )}
{(%( ))}
{(%( )
)}
{(%( )foo())}
{(%( )foo()
)}
{(
bar()%( ))}

View File

@ -0,0 +1,35 @@
{
}
{
}
{
bar()}
{
bar()
}
{
bar()
}
{(
)}
{(
)}
{(
foo())}
{(
foo()
)}
{(
bar()
)}

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/filetype/go.kak"
set buffer filetype go

View File

@ -0,0 +1 @@
c<ret>

View File

@ -0,0 +1,12 @@
if true {%( )}
if true {%( )
}
if true {%( )bar()}
if true {%( )bar()
}
if true {
bar()%( )}

View File

@ -0,0 +1,17 @@
if true {
}
if true {
}
if true {
bar()}
if true {
bar()
}
if true {
bar()
}

View File

@ -0,0 +1,3 @@
source "%val{runtime}/colors/default.kak"
source "%val{runtime}/rc/filetype/go.kak"
set buffer filetype go