summaryrefslogtreecommitdiffstats
path: root/t/chainlint/cuddled.test
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--t/chainlint/cuddled.test22
1 files changed, 22 insertions, 0 deletions
diff --git a/t/chainlint/cuddled.test b/t/chainlint/cuddled.test
new file mode 100644
index 0000000..257b5b5
--- /dev/null
+++ b/t/chainlint/cuddled.test
@@ -0,0 +1,22 @@
+# LINT: first subshell statement cuddled with opening "("
+(cd foo &&
+ bar
+) &&
+
+# LINT: same with missing "&&"
+(cd foo
+ bar
+) &&
+
+# LINT: closing ")" cuddled with final subshell statement
+(
+ cd foo &&
+ bar) &&
+
+# LINT: "(" and ")" cuddled with first and final subshell statements
+(cd foo &&
+ bar) &&
+
+# LINT: same with missing "&&"
+(cd foo
+ bar)