summaryrefslogtreecommitdiffstats
path: root/tests/oo.test
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2012-01-25 14:39:55 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2012-01-25 14:39:55 (GMT)
commit68fbac8d0f24ffb16077c6c3ecd6c1a61ab16bb1 (patch)
treecd1368cc4eeee7ad19d71b6daad4256bcffb9205 /tests/oo.test
parent8df49a02756833a2aefa9dcba660412037e4f1c4 (diff)
downloadtcl-68fbac8d0f24ffb16077c6c3ecd6c1a61ab16bb1.zip
tcl-68fbac8d0f24ffb16077c6c3ecd6c1a61ab16bb1.tar.gz
tcl-68fbac8d0f24ffb16077c6c3ecd6c1a61ab16bb1.tar.bz2
* generic/tclOO.c (Tcl_CopyObjectInstance): [Bug 3474460]: When
copying an object, make sure that the configuration of the variable resolver is also duplicated.
Diffstat (limited to 'tests/oo.test')
-rw-r--r--tests/oo.test22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/oo.test b/tests/oo.test
index e5a17f1..67535c9 100644
--- a/tests/oo.test
+++ b/tests/oo.test
@@ -1650,6 +1650,28 @@ test oo-15.3 {OO: class cloning} {
bar destroy
return $result
} {::foo->::baseline ::foo->::baseline ::bar->::tester ::bar->::tester}
+test oo-15.4 {OO: object cloning - Bug 3474460} -setup {
+ oo::class create ArbitraryClass
+} -body {
+ ArbitraryClass create foo
+ oo::objdefine foo variable a b c
+ oo::copy foo bar
+ info object variable bar
+} -cleanup {
+ ArbitraryClass destroy
+} -result {a b c}
+test oo-15.5 {OO: class cloning - Bug 3474460} -setup {
+ oo::class create ArbitraryClass
+} -body {
+ oo::class create Foo {
+ superclass ArbitraryClass
+ variable a b c
+ }
+ oo::copy Foo Bar
+ info class variable Bar
+} -cleanup {
+ ArbitraryClass destroy
+} -result {a b c}
test oo-16.1 {OO: object introspection} -body {
info object