Skip to content

Commit

Permalink
add missed features/object/to-string entry point
Browse files Browse the repository at this point in the history
  • Loading branch information
zloirock committed May 5, 2018
1 parent 6e05445 commit a929ec6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/core-js/features/object/to-string.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
require('../../modules/es.object.to-string');
var classof = require('../../internals/classof');

module.exports = function (it) {
return '[object ' + classof(it) + ']';
};
1 change: 1 addition & 0 deletions tests/commonjs.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ for (const _PATH of ['../packages/core-js-pure', '../packages/core-js']) {
ok(load('features/object/prevent-extensions')({}));
ok(load('features/object/seal')({}));
ok(load('features/object/set-prototype-of')({}, []) instanceof Array);
ok(load('features/object/to-string')([]) === '[object Array]');
ok(load('features/object/entries')({ q: 2 })[0][0] === 'q');
ok(load('features/object/values')({ q: 2 })[0] === 2);
ok(load('features/object/get-own-property-descriptors')({ q: 1 }).q.enumerable);
Expand Down

0 comments on commit a929ec6

Please sign in to comment.