Index: tests/linearization.test =================================================================== diff -u -r275da34d3d7a874a451eced58242b738c8a37d1a -ra963e8896fd07c345ccfa034cbd043344edbf083 --- tests/linearization.test (.../linearization.test) (revision 275da34d3d7a874a451eced58242b738c8a37d1a) +++ tests/linearization.test (.../linearization.test) (revision a963e8896fd07c345ccfa034cbd043344edbf083) @@ -81,7 +81,7 @@ # # Boat example DHHM 94; # R. Ducournau, M. Habib, M. Huchard, and M.L. Mugnier. Proposal for a Monotonic Multiple Inheritance Linearization. - # see: http://www2.lirmm.fr/~ducour/Publis/DHHM-oopsla94.pdf + # see: https://www2.lirmm.fr/~ducour/Publis/DHHM-oopsla94.pdf # nx::Class create boat ;# 8 @@ -126,9 +126,32 @@ } +nx::test case boat-crash { + # + # This variant of the boat test case lead to problems in earlier + # versions depending on the deletion order during the cleanup in the + # test case. + # + nx::Class create boat ;# 8 + nx::Class create dayboat -superclass boat ;# 6 + nx::Class create wheelboat -superclass boat ;# 7 + nx::Class create engineless -superclass dayboat ;# 3 + nx::Class create pedalwheelboat -superclass {engineless wheelboat} ;# 2 + nx::Class create smallmultihull -superclass dayboat ;# 5 + nx::Class create smallcatamaran -superclass smallmultihull ;# 4 + nx::Class create pedalo -superclass {pedalwheelboat smallcatamaran};# 1 + + ? {::smallcatamaran destroy} "" + ? {::boat destroy} "" + ? {::pedalo info heritage} {::pedalwheelboat ::engineless ::dayboat ::wheelboat ::nx::Object} + ? {::pedalo destroy} "" + ? {::pedalwheelboat info heritage} {::engineless ::dayboat ::wheelboat ::nx::Object} +} + + # # Local variables: # mode: tcl # tcl-indent-level: 2 # indent-tabs-mode: nil -# End: \ No newline at end of file +# End: