Module: wine Branch: master Commit: 6ab3ed7ce43144c9ac8d308e35f3366d34250cf0 URL: https://source.winehq.org/git/wine.git/?a=commit;h=6ab3ed7ce43144c9ac8d308e3...
Author: Andreas Maier staubim@quantentunnel.de Date: Thu Apr 18 21:08:41 2019 +0200
jscript_test: Simple test for Enumerator().
Signed-off-by: Andreas Maier staubim@quantentunnel.de Signed-off-by: Jacek Caban jacek@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/jscript/tests/api.js | 4 ++++ 1 file changed, 4 insertions(+)
diff --git a/dlls/jscript/tests/api.js b/dlls/jscript/tests/api.js index 38b2e66..78c0958 100644 --- a/dlls/jscript/tests/api.js +++ b/dlls/jscript/tests/api.js @@ -58,6 +58,8 @@ testNoEnumerables("Function"); testNoEnumerables("Function.prototype"); testNoEnumerables("testNoEnumerates"); testNoEnumerables("VBArray"); +testNoEnumerables("new Enumerator([])"); +testNoEnumerables("Enumerator([])");
ok(Object.propertyIsEnumerable("prototype") === false, "Object.prototype is enumerable"); ok(Math.propertyIsEnumerable("E") === false, "Math.E is enumerable"); @@ -341,6 +343,8 @@ ok(tmp === "[object Object]", "toString.call(this) = " + tmp); ok(tmp === "[object Object]", "toString.call(arguments) = " + tmp); tmp = Object.prototype.toString.call(new VBArray(createArray())); ok(tmp === "[object Object]", "toString.call(new VBArray()) = " + tmp); +(tmp = new Enumerator([])).f = Object.prototype.toString; +ok(tmp.f() === "[object Object]", "tmp.f() = " + tmp.f());
function TSTestConstr() {} TSTestConstr.prototype = { toString: function() { return "test"; } };