Skip to content
Permalink
Browse files
Configurability test of prototype's properties in fast/dom/webidl-ope…
…rations-on-node-prototype.html is wrong

https://bugs.webkit.org/show_bug.cgi?id=124602

Reviewed by Darin Adler.

The test case landed in r159100 checks, among other tests, for configurability of properties on the Node's
interface prototype object. The test deletes the tested property from the prototype object and checks that
the property is undefined. This works for the Node's prototype object but is not technically correct since
there might be a property with the same identifier that's located upwards on the prototype chain.

Rather than testing that the property on the prototype object is undefined after it is deleted, a failure
should be reported if the value of the property remains the same even after it's deleted from the object.

* fast/dom/webidl-operations-on-node-prototype.html:


Canonical link: https://commits.webkit.org/142815@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@159558 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
zdobersek committed Nov 20, 2013
1 parent 672e46e commit fd2ee47b8f2553e0a047791326c848509b1226c5
Showing 2 changed files with 18 additions and 1 deletion.
@@ -1,3 +1,20 @@
2013-11-20 Zan Dobersek <zdobersek@igalia.com>

Configurability test of prototype's properties in fast/dom/webidl-operations-on-node-prototype.html is wrong
https://bugs.webkit.org/show_bug.cgi?id=124602

Reviewed by Darin Adler.

The test case landed in r159100 checks, among other tests, for configurability of properties on the Node's
interface prototype object. The test deletes the tested property from the prototype object and checks that
the property is undefined. This works for the Node's prototype object but is not technically correct since
there might be a property with the same identifier that's located upwards on the prototype chain.

Rather than testing that the property on the prototype object is undefined after it is deleted, a failure
should be reported if the value of the property remains the same even after it's deleted from the object.

* fast/dom/webidl-operations-on-node-prototype.html:

2013-11-19 Ryosuke Niwa <rniwa@webkit.org>

Enable HTMLTemplateElement on Mac port
@@ -32,7 +32,7 @@
test: function() {
var propertyValue = Node.prototype[property];
delete Node.prototype[property];
if (Node.prototype[property] !== undefined)
if (Node.prototype[property] === propertyValue)
testFailed("Property " + property + " should be configurable.");
Node.prototype[property] = propertyValue;
}

0 comments on commit fd2ee47

Please sign in to comment.