Skip to content

Commit 3c95873

Browse files
committed
tests: misc: improve 'info statics' test
To show that it returns the current values, not just the original values Signed-off-by: Steve Bennett <steveb@workware.net.au>
1 parent 2857084 commit 3c95873

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

tests/misc.test

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -579,8 +579,10 @@ test eval-list-1.1 {Lost string rep with list} {
579579

580580
test info-statics-1.1 {info statics commands} {
581581
set x 1
582-
proc a {} {x {y 2}} {}
583-
lsort [info statics a]
584-
} {1 2 x y}
582+
proc a {} {x {y 2}} { incr x; incr y}
583+
a
584+
# Returns the dict of the current static variables
585+
info statics a
586+
} {x 2 y 3}
585587

586588
testreport

0 commit comments

Comments
 (0)