Author: toshok
Date: 2006-11-15 19:37:36 -0500 (Wed, 15 Nov 2006)
New Revision: 67964

Modified:
   trunk/mcs/class/Managed.Windows.Forms/Test/System.Windows.Forms/FormTest.cs
Log:
add a unit test dealing with disposing of a form's owner

Modified: 
trunk/mcs/class/Managed.Windows.Forms/Test/System.Windows.Forms/FormTest.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/Test/System.Windows.Forms/FormTest.cs 
2006-11-16 00:36:51 UTC (rev 67963)
+++ trunk/mcs/class/Managed.Windows.Forms/Test/System.Windows.Forms/FormTest.cs 
2006-11-16 00:37:36 UTC (rev 67964)
@@ -216,6 +216,19 @@
                }
 
                [Test]
+               public void DisposeOwnerTest ()
+               {
+                       Form f1 = new Form ();
+                       Form f2 = new Form ();
+
+                       f2.Owner = f1;
+
+                       f1.Dispose ();
+
+                       Assert.IsNull (f2.Owner, "1");
+               }
+
+               [Test]
                [ExpectedException (typeof (ObjectDisposedException))]
                public void AccessDisposedForm ()
                {

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to