diff options
author | Chad Austin <chad@imvu.com> | 2014-05-02 16:17:55 -0700 |
---|---|---|
committer | Bruce Mitchener <bruce.mitchener@gmail.com> | 2014-05-21 22:57:28 +0700 |
commit | 95a583b28ac063c3e813e61ea938bb93de910d66 (patch) | |
tree | f46864326ca8460672e46de24332d559a747c35d /tests | |
parent | 6ce9851175ef56f894bd537fbf871c363f8bd402 (diff) |
make optional methods work
Diffstat (limited to 'tests')
-rw-r--r-- | tests/embind/embind.test.js | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/tests/embind/embind.test.js b/tests/embind/embind.test.js index d42e66d2..513ab1d4 100644 --- a/tests/embind/embind.test.js +++ b/tests/embind/embind.test.js @@ -1693,8 +1693,6 @@ module({ assert.equal("concrete", result); }); -/* ENABLE THESE AS THEY PASS - test("optional methods are externally visible", function() { var instance = new Empty; var result = instance.optionalMethod("_123"); @@ -1702,16 +1700,17 @@ module({ assert.equal("optional_123", result); }); - test("optional methods", function() { + test("optional methods: not defined", function() { var instance = new Empty; var result = cm.callOptionalMethod(instance, "_123"); instance.delete(); assert.equal("optional_123", result); }); +/* ENABLE THESE AS THEY PASS test("can call parent implementation from within derived implementation", function() { var parent = cm.AbstractClass; - var ExtendsOptionalMethod = parent.extend({ + var ExtendsOptionalMethod = parent.extend("ExtendsOptionalMethod", { optionalMethod: function(s) { return "optionaljs_" + parent.prototype.optionalMethod.call(this, s); }, |