mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-30 05:19:19 +00:00
add tests for go config parser
This commit is contained in:
parent
0aa4c850ba
commit
8754d80832
2 changed files with 27 additions and 4 deletions
|
|
@ -19,13 +19,18 @@ func TestConfigParsing(t *testing.T) {
|
|||
os.Mkdir(filepath.Join(tdir, "sub"), 0o700)
|
||||
os.WriteFile(conf_file, []byte(
|
||||
`error main
|
||||
# ignore me
|
||||
# igno
|
||||
\re me
|
||||
a one
|
||||
#: other
|
||||
include sub/b.conf
|
||||
include
|
||||
\ sub/b.conf
|
||||
b
|
||||
include non-existent
|
||||
globinclude sub/c?.conf
|
||||
include non-exis
|
||||
\tent
|
||||
globin
|
||||
\clude sub/c?.c
|
||||
\onf
|
||||
`), 0o600)
|
||||
os.WriteFile(filepath.Join(tdir, "sub/b.conf"), []byte("incb cool\ninclude a.conf"), 0o600)
|
||||
os.WriteFile(filepath.Join(tdir, "sub/c1.conf"), []byte("inc1 cool"), 0o600)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue