Author: jmorliaguet
Date: Sat Apr  1 18:18:35 2006
New Revision: 2755

Modified:
   cpsskins/branches/jmo-perspectives/ui/framework/cpsskins.js
   cpsskins/branches/jmo-perspectives/ui/framework/tests/unit/cpsskins_test.html
Log:

- test fix



Modified: cpsskins/branches/jmo-perspectives/ui/framework/cpsskins.js
==============================================================================
--- cpsskins/branches/jmo-perspectives/ui/framework/cpsskins.js (original)
+++ cpsskins/branches/jmo-perspectives/ui/framework/cpsskins.js Sat Apr  1 
18:18:35 2006
@@ -1576,7 +1576,7 @@
         new_data[field] = current_data[field];
       }
     });
-    if (!this._compareData(this.read(), new_data)) {;
+    if (!this._data || !this._compareData(this.read(), new_data)) {;
       this.model.writeData(new_data);
       CPSSkins.notify('stored', {'publisher': this});
     }

Modified: 
cpsskins/branches/jmo-perspectives/ui/framework/tests/unit/cpsskins_test.html
==============================================================================
--- 
cpsskins/branches/jmo-perspectives/ui/framework/tests/unit/cpsskins_test.html   
    (original)
+++ 
cpsskins/branches/jmo-perspectives/ui/framework/tests/unit/cpsskins_test.html   
    Sat Apr  1 18:18:35 2006
@@ -307,9 +307,9 @@
     }},
 
     testAddActions: function() { with(this) {
-      assertEqual(inspect({}), inspect(CPSSkins._handlers))
+      assertEqual(inspect({}), inspect(CPSSkins._action_handlers))
       CPSSkins.addActions({'handler': handler});
-      assertEqual(inspect({'handler': handler}), inspect(CPSSkins._handlers))
+      assertEqual(inspect({'handler': handler}), 
inspect(CPSSkins._action_handlers))
     }},
 
     /* Identifiable */
@@ -402,7 +402,7 @@
     testSetData: function() { with(this) {
       var model_e2 = CPSSkins.Canvas.getModel(e2);
 
-      assertEqual(inspect({'a': 'string', 'b': 'string', 'c': 'boolean'}),
+      assertEqual(inspect({"a": "string", "b": "string", "c": "boolean"}),
                   inspect(model_e2.schema));
 
       // setData cannot set undefined fields
-- 
http://lists.nuxeo.com/mailman/listinfo/z3lab-checkins

Reply via email to