File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ describe('createError(status)', function () {
1212 } )
1313
1414 describe ( 'Extending Existing Errors with HTTP Properties' , function ( ) {
15- it ( 'should extend an existing error with HTTP properties without altering its prototype' , function ( ) {
15+ it ( 'should extend existing error without altering its prototype or replacing the object ' , function ( ) {
1616 var nativeError = new Error ( 'This is a test error' )
1717
1818 // Extend the error with HTTP semantics
@@ -26,6 +26,8 @@ describe('createError(status)', function () {
2626 assert ( httpError instanceof Error )
2727
2828 assert . strictEqual ( Object . getPrototypeOf ( httpError ) , Error . prototype )
29+
30+ assert . strictEqual ( nativeError , httpError )
2931 } )
3032 } )
3133
You can’t perform that action at this time.
0 commit comments