Added test highlighting a missing feature

Added a test to show that current implementation of 'cloneRecord' does not process DirectLogins yet.
This commit is contained in:
Giulio Cesare Solaroli 2014-08-26 21:54:48 +02:00
parent 316dff637f
commit acf5363fe2

View File

@ -2048,6 +2048,12 @@ console.log("PROXY", proxy);
deferredResult.addCallback(MochiKit.Base.itemgetter('length')); deferredResult.addCallback(MochiKit.Base.itemgetter('length'));
deferredResult.addTest(2, "The selected record has 2 fields"); deferredResult.addTest(2, "The selected record has 2 fields");
deferredResult.addMethod(user, 'getRecord', recordID);
deferredResult.addMethodcaller('directLogins');
deferredResult.addCallback(MochiKit.Base.keys);
deferredResult.addCallback(MochiKit.Base.itemgetter('length'));
deferredResult.addTest(1, "The selected record has 1 direct logins");
deferredResult.addMethod(user, 'getRecord', recordID); deferredResult.addMethod(user, 'getRecord', recordID);
deferredResult.addMethod(user, 'cloneRecord'); deferredResult.addMethod(user, 'cloneRecord');
deferredResult.addMethodcaller('reference'); deferredResult.addMethodcaller('reference');
@ -2069,6 +2075,12 @@ console.log("PROXY", proxy);
deferredResult.addCallback(MochiKit.Base.itemgetter('length')); deferredResult.addCallback(MochiKit.Base.itemgetter('length'));
deferredResult.addTest(2, "The cloned record has 2 fields too"); deferredResult.addTest(2, "The cloned record has 2 fields too");
deferredResult.addCallback(function () { return clonedRecordID; })
deferredResult.addMethod(user, 'getRecord');
deferredResult.addMethodcaller('directLogins');
deferredResult.addCallback(MochiKit.Base.keys);
deferredResult.addCallback(MochiKit.Base.itemgetter('length'));
deferredResult.addTest(1, "The cloned record has 1 direct logins");
deferredResult.callback(); deferredResult.callback();