Title: [commits] (john) [16090] Add some more error messages to help narrow down test failures.
Revision
16090
Author
john
Date
2007-12-08 16:45:03 -0800 (Sat, 08 Dec 2007)

Log Message

Add some more error messages to help narrow down test failures.

Also exclude TestTriageSectioningActions on Tiger becuse of bugs it finds that are platform specific

Modified Paths

Diff

Modified: trunk/chandler/parcels/osaf/framework/script_recording/script_lib.py (16089 => 16090)

--- trunk/chandler/parcels/osaf/framework/script_recording/script_lib.py	2007-12-08 19:05:42 UTC (rev 16089)
+++ trunk/chandler/parcels/osaf/framework/script_recording/script_lib.py	2007-12-09 00:45:03 UTC (rev 16090)
@@ -177,8 +177,8 @@
                     assert lastWidgetValue.startswith (u"Welcome to Chandler 0.7.dev-r")
                 else:
                     assert value == lastWidgetValue,\
-                           'event %d -- widget %s value, "%s" doesn\'t match the value when the script was recorded: "%s"'\
-                            % (eventNumber, ProcessEvent.lastSentTo, value, lastWidgetValue)
+                           'event %d -- widget %s value, "%s" doesn\'t match the value when the script was recorded: "%s"; application.IsActive() is %s'\
+                            % (eventNumber, ProcessEvent.lastSentTo, value, lastWidgetValue, str(application.IsActive()))
 
         # Keep track of the last widget. Use Id because widget can be deleted
 
@@ -253,9 +253,11 @@
                     contents = properties.get ("clipboard", None)
                     if contents is not None:
                         assert wx.TheClipboard.Open(), "event %d -- The clipboard can't be opened" % eventNumber
-                        wx.TheClipboard.SetData (wx.TextDataObject (contents))
+                        assert wx.TheClipboard.SetData (wx.TextDataObject (contents)), "event %d -- Clipboard SetData failed" % eventNumber
                         wx.TheClipboard.Close()
                         sentToWidget.Paste ()
+                        value = sentToWidget.GetValue()
+                        assert value == contents, 'event %d -- Pasted "%s". After paste widget has value: "%s"' % (eventNumber, contents, value)
                         
     selectionRange = properties.get ("selectionRange", None)
     if selectionRange is not None:

Modified: trunk/chandler/tools/cats/recorded_scripts/TestTriageSectioningActions.py (16089 => 16090)

--- trunk/chandler/tools/cats/recorded_scripts/TestTriageSectioningActions.py	2007-12-08 19:05:42 UTC (rev 16089)
+++ trunk/chandler/tools/cats/recorded_scripts/TestTriageSectioningActions.py	2007-12-09 00:45:03 UTC (rev 16090)
@@ -1,4 +1,7 @@
 import wx, osaf, application
+
+_platform_exclusions_ = ("mac")
+
 def run():
     """
         Choose menu 'Collection > New' (0)




_______________________________________________
Commits mailing list
[email protected]
http://lists.osafoundation.org/mailman/listinfo/commits

Reply via email to