test that folders containing a - file won't hang forever
This commit is contained in:
parent
8ee8420408
commit
fe21ff905d
|
@ -86,6 +86,7 @@ func TestFmt_Recursive(t *testing.T) {
|
||||||
"potato": unformattedHCL,
|
"potato": unformattedHCL,
|
||||||
"foo/bar/potato": unformattedHCL,
|
"foo/bar/potato": unformattedHCL,
|
||||||
"bar.pkr.hcl": unformattedHCL,
|
"bar.pkr.hcl": unformattedHCL,
|
||||||
|
"-": unformattedHCL,
|
||||||
},
|
},
|
||||||
fileCheck: fileCheck{
|
fileCheck: fileCheck{
|
||||||
expectedContent: map[string]string{
|
expectedContent: map[string]string{
|
||||||
|
@ -94,6 +95,7 @@ func TestFmt_Recursive(t *testing.T) {
|
||||||
"potato": unformattedHCL,
|
"potato": unformattedHCL,
|
||||||
"foo/bar/potato": unformattedHCL,
|
"foo/bar/potato": unformattedHCL,
|
||||||
"bar.pkr.hcl": formattedHCL,
|
"bar.pkr.hcl": formattedHCL,
|
||||||
|
"-": unformattedHCL,
|
||||||
}},
|
}},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -103,12 +105,14 @@ func TestFmt_Recursive(t *testing.T) {
|
||||||
"foo/bar/baz.pkr.hcl": unformattedHCL,
|
"foo/bar/baz.pkr.hcl": unformattedHCL,
|
||||||
"foo/bar/baz/woo.pkrvars.hcl": unformattedHCL,
|
"foo/bar/baz/woo.pkrvars.hcl": unformattedHCL,
|
||||||
"bar.pkr.hcl": unformattedHCL,
|
"bar.pkr.hcl": unformattedHCL,
|
||||||
|
"-": unformattedHCL,
|
||||||
},
|
},
|
||||||
fileCheck: fileCheck{
|
fileCheck: fileCheck{
|
||||||
expectedContent: map[string]string{
|
expectedContent: map[string]string{
|
||||||
"foo/bar/baz.pkr.hcl": unformattedHCL,
|
"foo/bar/baz.pkr.hcl": unformattedHCL,
|
||||||
"foo/bar/baz/woo.pkrvars.hcl": unformattedHCL,
|
"foo/bar/baz/woo.pkrvars.hcl": unformattedHCL,
|
||||||
"bar.pkr.hcl": formattedHCL,
|
"bar.pkr.hcl": formattedHCL,
|
||||||
|
"-": unformattedHCL,
|
||||||
}},
|
}},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue