Skip to content
Snippets Groups Projects
Commit ed2bcdc0 authored by Zirak's avatar Zirak Committed by Leo Balter
Browse files

Add missing test cases for set __proto__ (#898)

Fixes #887
parent 6ef9cef4
No related branches found
No related tags found
No related merge requests found
......@@ -12,8 +12,24 @@ features: [Symbol]
---*/
var set = Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set;
var subject = {};
assert.sameValue(set.call(true), undefined, 'boolean');
assert.sameValue(
Object.getPrototypeOf(subject), Object.prototype, 'following boolean'
);
assert.sameValue(set.call(1), undefined, 'number');
assert.sameValue(
Object.getPrototypeOf(subject), Object.prototype, 'following number'
);
assert.sameValue(set.call('string'), undefined, 'string');
assert.sameValue(
Object.getPrototypeOf(subject), Object.prototype, 'following string'
);
assert.sameValue(set.call(Symbol('')), undefined, 'symbol');
assert.sameValue(
Object.getPrototypeOf(subject), Object.prototype, 'following symbol'
);
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment