summaryrefslogtreecommitdiffstats
path: root/tests/regexp.test
diff options
context:
space:
mode:
Diffstat (limited to 'tests/regexp.test')
-rw-r--r--tests/regexp.test20
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/regexp.test b/tests/regexp.test
index 9fff262..ac6f8a3 100644
--- a/tests/regexp.test
+++ b/tests/regexp.test
@@ -15,7 +15,7 @@ if {"::tcltest" ni [namespace children]} {
package require tcltest 2
namespace import -force ::tcltest::*
}
-
+interp regexp {} pcre
unset -nocomplain foo
testConstraint exec [llength [info commands exec]]
@@ -247,13 +247,13 @@ test regexp-6.2 {regexp errors} {
} {1 {wrong # args: should be "regexp ?-option ...? exp string ?matchVar? ?subMatchVar ...?"}}
test regexp-6.3 {regexp errors} {
list [catch {regexp -gorp a} msg] $msg
-} {1 {bad option "-gorp": must be -all, -about, -indices, -inline, -expanded, -line, -linestop, -lineanchor, -nocase, -start, or --}}
-test regexp-6.4 {regexp errors} {
- list [catch {regexp a( b} msg] $msg
-} {1 {couldn't compile regular expression pattern: parentheses () not balanced}}
-test regexp-6.5 {regexp errors} {
+} {1 {bad option "-gorp": must be -all, -about, -indices, -inline, -expanded, -line, -linestop, -lineanchor, -nocase, -start, -type, or --}}
+test regexp-6.4 {regexp errors} -body {
list [catch {regexp a( b} msg] $msg
-} {1 {couldn't compile regular expression pattern: parentheses () not balanced}}
+} -match glob -result {1 {couldn't compile*}}
+test regexp-6.5 {regexp errors} -body {
+ list [catch {regexp a) b} msg] $msg
+} -match glob -result {1 {couldn't compile*}}
test regexp-6.6 {regexp errors} {
list [catch {regexp a a f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1 f1} msg] $msg
} {0 1}
@@ -453,10 +453,10 @@ test regexp-11.4 {regsub errors} {
} {1 {wrong # args: should be "regsub ?-option ...? exp string subSpec ?varName?"}}
test regexp-11.5 {regsub errors} {
list [catch {regsub -gorp a b c} msg] $msg
-} {1 {bad option "-gorp": must be -all, -nocase, -expanded, -line, -linestop, -lineanchor, -start, or --}}
-test regexp-11.6 {regsub errors} {
+} {1 {bad option "-gorp": must be -all, -nocase, -expanded, -line, -linestop, -lineanchor, -start, -type, or --}}
+test regexp-11.6 {regsub errors} -body {
list [catch {regsub -nocase a( b c d} msg] $msg
-} {1 {couldn't compile regular expression pattern: parentheses () not balanced}}
+} -match glob -result {1 {couldn't compile*}}
test regexp-11.7 {regsub errors} -setup {
unset -nocomplain f1
} -body {