michael@0: /* michael@0: * Any copyright is dedicated to the Public Domain. michael@0: * http://creativecommons.org/licenses/publicdomain/ michael@0: */ michael@0: michael@0: var BUGNUMBER = 518103; michael@0: var summary = 'lambda constructor "method" vs. instanceof'; michael@0: var actual; michael@0: var expect; michael@0: michael@0: printBugNumber(BUGNUMBER); michael@0: printStatus(summary); michael@0: michael@0: var Y = {widget: {}}; michael@0: michael@0: Y.widget.DataSource = function () {}; michael@0: Y.widget.DS_JSArray = function (A) { this.data = A; }; michael@0: Y.widget.DS_JSArray.prototype = new Y.widget.DataSource(); michael@0: michael@0: var J = new Y.widget.DS_JSArray( [ ] ); michael@0: michael@0: actual = J instanceof Y.widget.DataSource; michael@0: expect = true; michael@0: michael@0: reportCompare(expect, actual, summary); michael@0: michael@0: printStatus("All tests passed!");