| Index: test/mjsunit/stack-traces.js
|
| diff --git a/test/mjsunit/stack-traces.js b/test/mjsunit/stack-traces.js
|
| index 46a16eb87a2db857a00f8d7de060af09ffc2fa00..fceba6fe1ce0b97acb1b21c4917fbdb7942c8f49 100644
|
| --- a/test/mjsunit/stack-traces.js
|
| +++ b/test/mjsunit/stack-traces.js
|
| @@ -331,3 +331,13 @@ Error.prepareStackTrace = function() { Error.prepareStackTrace = "custom"; };
|
| new Error().stack;
|
|
|
| assertEquals("custom", Error.prepareStackTrace);
|
| +
|
| +// Check that the formatted stack trace can be set to undefined.
|
| +error = new Error();
|
| +error.stack = undefined;
|
| +assertEquals(undefined, error.stack);
|
| +
|
| +// Check that the stack trace accessors are not forcibly set.
|
| +var my_error = {};
|
| +Object.freeze(my_error);
|
| +assertThrows(function() { Error.captureStackTrace(my_error); });
|
|
|