diff --git a/syntax/filetests_test.go b/syntax/filetests_test.go index 5ca3f7286..32808c473 100644 --- a/syntax/filetests_test.go +++ b/syntax/filetests_test.go @@ -2671,7 +2671,7 @@ var fileTests = []testCase{ }), }, { - Strs: []string{"$((a /= b))"}, + Strs: []string{"$((a /= b))", "$((a/=b))"}, common: arithmExp(&BinaryArithm{ Op: QuoAssgn, X: litWord("a"), diff --git a/syntax/printer_test.go b/syntax/printer_test.go index 1170b5dd3..1e054ee44 100644 --- a/syntax/printer_test.go +++ b/syntax/printer_test.go @@ -718,6 +718,10 @@ func TestPrintKeepPadding(t *testing.T) { func TestPrintMinify(t *testing.T) { var tests = [...]printCase{ samePrint("echo foo bar $a $(b)"), + { + "#comment", + "", + }, { "foo #comment", "foo",