From 461ef3c5186ce4df67039615b30b84b0c86d7da4 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 28 Apr 2012 16:04:34 -0400 Subject: [PATCH] Add some shell indentation test cases. * test/indent/shell.sh: * test/indent/shell.rc: Add some test cases. --- test/ChangeLog | 5 +++++ test/indent/shell.rc | 9 ++++++++- test/indent/shell.sh | 4 +++- 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/test/ChangeLog b/test/ChangeLog index ff38a8fa9e..0f3db27f18 100644 --- a/test/ChangeLog +++ b/test/ChangeLog @@ -1,3 +1,8 @@ +2012-04-28 Stefan Monnier + + * indent/shell.sh: + * indent/shell.rc: Ad some test cases. + 2012-04-24 Stefan Monnier * indent/ruby.rb: New file, to test new syntax-propertize code. diff --git a/test/indent/shell.rc b/test/indent/shell.rc index 841223555b..e5c63e335b 100755 --- a/test/indent/shell.rc +++ b/test/indent/shell.rc @@ -1,7 +1,10 @@ #!/bin/rc if (foo) { - echo 1 + echo 1 \ + toto \ + tutu + titi } if not { echo 2 @@ -23,6 +26,10 @@ switch ($a) { for (i in a b c) echo "$i" # KNOWN INDENT BUG echo titi + if (foo) + echo 3 # KNOWN INDENT BUG + if not + echo 4 # KNOWN INDENT BUG case * echo other diff --git a/test/indent/shell.sh b/test/indent/shell.sh index 89f47d0bfe..26a01dc3bd 100755 --- a/test/indent/shell.sh +++ b/test/indent/shell.sh @@ -13,6 +13,7 @@ foo () { case toto in a) hello # KNOWN INDENT BUG ;; b) hi # KNOWN INDENT BUG + ;; c) hi # KNOWN INDENT BUG esac case $toto in @@ -34,7 +35,8 @@ foo () { sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | - cat # KNOWN INDENT BUG + grep '.' | # KNOWN INDENT BUG + sed 1d case toto in -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ -- 2.20.1