diff options
author | andy <andrew.m.goth@gmail.com> | 2016-12-13 19:21:16 (GMT) |
---|---|---|
committer | andy <andrew.m.goth@gmail.com> | 2016-12-13 19:21:16 (GMT) |
commit | b7a71bcd69f9d3407f3f0e6112e413671a564423 (patch) | |
tree | 21491c5d0970862708838d7c5dd710ca62e66756 | |
parent | 48a2f51ec5e162377ff9397a32538f0badd0bd10 (diff) | |
download | tcl-b7a71bcd69f9d3407f3f0e6112e413671a564423.zip tcl-b7a71bcd69f9d3407f3f0e6112e413671a564423.tar.gz tcl-b7a71bcd69f9d3407f3f0e6112e413671a564423.tar.bz2 |
Rework array size increase/decrease tests to avoid dummy list element
-rw-r--r-- | tests/array.test | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/array.test b/tests/array.test index cfe0d77..3b680ca 100644 --- a/tests/array.test +++ b/tests/array.test @@ -741,23 +741,23 @@ foreach { exists 1 1 size 1 2 names {e} {e f} - get {e 1} {e 1 f {}} + get {e 1} {e 1 f 2} } { test { name array-6.14.$cmd desc {increasing array size: \[array $cmd\]} {scalar cmd} $cmd {array a} {e 1} - body {list [array $cmd a] [set a(f) {}] [array $cmd a]} - result {[list $small {} $large]} + body {list [array $cmd a][set a(f) 2; list] [array $cmd a]} + result {[list $small $large]} } test { name array-6.15.$cmd desc {decreasing array size: \[array $cmd\]} {scalar cmd} $cmd - {array a} {e 1 f {}} - body {list [array $cmd a] [unset a(f)] [array $cmd a]} - result {[list $large {} $small]} + {array a} {e 1 f 2} + body {list [array $cmd a][unset a(f)] [array $cmd a]} + result {[list $large $small]} } } |