diff --git a/test/test.js b/test/test.js index 7403ed75e..f61a5fea0 100644 --- a/test/test.js +++ b/test/test.js @@ -1089,9 +1089,20 @@ 'String': String.prototype }, function(object, builtin) { - var keys = []; - func(object, function(value, key) { keys.push(key); }); - deepEqual(keys, [], 'non-enumerable properties on ' + builtin + '.prototype'); + var message = 'non-enumerable properties on ' + builtin + '.prototype', + props = []; + + func(object, function(value, prop) { + props.push(prop); + }); + + if (/Error/.test(builtin)) { + ok(_.every(['constructor', 'toString'], function(prop) { + return !_.contains(props, prop); + }), message); + } else { + deepEqual(props, [], message); + } }); });