Browse Source

more testing

Charlie Kindel 5 years ago
parent
commit
af88f610b0
1 changed files with 14 additions and 0 deletions
  1. 14 0
      UICatalog/UICatalog.cs

+ 14 - 0
UICatalog/UICatalog.cs

@@ -85,8 +85,22 @@ namespace UICatalog {
 				scenario.Init (Application.Top, _baseColorScheme);
 				scenario.Setup ();
 				scenario.Run ();
+
+#if DEBUG
+				foreach (var inst in Responder.Instances) {
+					Debug.Assert (inst.WasDisposed);
+				}
+				Responder.Instances.Clear();
+#endif
+
 				scenario = GetScenarioToRun ();
 			}
+
+#if DEBUG
+			foreach (var inst in Responder.Instances) {
+				Debug.Assert (inst.WasDisposed);
+			}
+#endif
 		}
 
 		/// <summary>