aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test-cases/case2_positive_lookahead/script.sh21
-rw-r--r--test-cases/case2_positive_lookahead/stdout.txt1
2 files changed, 22 insertions, 0 deletions
diff --git a/test-cases/case2_positive_lookahead/script.sh b/test-cases/case2_positive_lookahead/script.sh
index 29c086e..f19441a 100644
--- a/test-cases/case2_positive_lookahead/script.sh
+++ b/test-cases/case2_positive_lookahead/script.sh
@@ -67,4 +67,25 @@ match x3 abcdef yes
match x3 abde no
echo x3
+fun x4 {
+ case $1 {
+ (?=((a.)*e))(?=((a..)*e)).* { echo yes }
+ .* { echo no }
+ }
+}
+match x4 '' no
+match x4 e yes
+match x4 a no
+match x4 ab no
+match x4 abe no
+match x4 abaaabe yes
+match x4 aaaaaae yes
+match x4 aaaaaaae no
+match x4 aaaaaaaae no
+match x4 aaaaaaaaae no
+match x4 aaaaaaaaaae no
+match x4 aaaaaaaaaaae no
+match x4 aaaaaaaaaaaae yes
+echo x4
+
echo done
diff --git a/test-cases/case2_positive_lookahead/stdout.txt b/test-cases/case2_positive_lookahead/stdout.txt
index e6f6ff8..ffa387f 100644
--- a/test-cases/case2_positive_lookahead/stdout.txt
+++ b/test-cases/case2_positive_lookahead/stdout.txt
@@ -2,4 +2,5 @@ begin
x1
x2
x3
+x4
done