mirror of https://github.com/tc39/test262.git
Improve coverage for Error.prototype.constructor
Extend coverage to include the property's enumerability, writability, and configurability.
This commit is contained in:
parent
4ec3eaaeb9
commit
f9efc46142
|
@ -1,18 +0,0 @@
|
|||
// Copyright 2009 the Sputnik authors. All rights reserved.
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
info: |
|
||||
The initial value of Error.prototype.constructor is the built-in Error
|
||||
constructor
|
||||
es5id: 15.11.4.1_A1_T1
|
||||
description: Checking Error.prototype.constructor
|
||||
---*/
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#1
|
||||
if (Error.prototype.constructor !== Error) {
|
||||
throw new Test262Error('#1: Error.prototype.constructor === Error. Actual: ' + Error.prototype.constructor);
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
|
@ -0,0 +1,14 @@
|
|||
// Copyright (c) 2021 the V8 project authors. All rights reserved.
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
/*---
|
||||
esid: sec-error.prototype.constructor
|
||||
description: Property descriptor of Error.prototype.constructor
|
||||
includes: [propertyHelper.js]
|
||||
---*/
|
||||
|
||||
verifyProperty(Error.prototype, 'constructor', {
|
||||
enumerable: false,
|
||||
writable: true,
|
||||
configurable: true,
|
||||
value: Error
|
||||
});
|
Loading…
Reference in New Issue