Debian Codegraph @

js/src/tests/test262/built-ins/Number/S15.7.2.1_A4.js

raw
1 // Copyright 2009 the Sputnik authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3
4 /*---
5 info: |
6 The [[Class]] property of the newly constructed object
7 is set to "Number"
8 es5id: 15.7.2.1_A4
9 description: For testing toString function is used
10 ---*/
11
12 delete Number.prototype.toString;
13
14 var obj = new Number();
15
16 assert.sameValue(obj.toString(), "[object Number]", 'obj.toString() must return "[object Number]"');
17
18 reportCompare(0, 0);