Changeset 250995 in webkit


Ignore:
Timestamp:
Oct 10, 2019, 4:44:01 PM (6 years ago)
Author:
mark.lam@apple.com
Message:

Modify JSTests/stress/string-overflow-createError-*.js tests to allow an OOME result.
https://bugs.webkit.org/show_bug.cgi?id=202828

Reviewed by Yusuke Suzuki.

The tests intentionally allocate a very large string. Hence, for some memory
limited configurations, it is perfectly reasonable for the test to throw an Out
Of Memory error.

  • stress/string-overflow-createError-builder.js:
  • stress/string-overflow-createError-fit.js:
Location:
trunk/JSTests
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/JSTests/ChangeLog

    r250932 r250995  
     12019-10-10  Mark Lam  <mark.lam@apple.com>
     2
     3        Modify JSTests/stress/string-overflow-createError-*.js tests to allow an OOME result.
     4        https://bugs.webkit.org/show_bug.cgi?id=202828
     5
     6        Reviewed by Yusuke Suzuki.
     7
     8        The tests intentionally allocate a very large string.  Hence, for some memory
     9        limited configurations, it is perfectly reasonable for the test to throw an Out
     10        Of Memory error.
     11
     12        * stress/string-overflow-createError-builder.js:
     13        * stress/string-overflow-createError-fit.js:
     14
    1152019-10-09  Yusuke Suzuki  <ysuzuki@apple.com>
    216
  • trunk/JSTests/stress/string-overflow-createError-builder.js

    r242910 r250995  
    1212// when the StringBuilder for the error message overflows,
    1313// "object is not a function" is used as message for the TypeError.
    14 if (exception.message != "object is not a function.")
     14if (exception.message != "object is not a function."
     15    && exception != "Error: Out of memory")
    1516    throw "FAILED";
  • trunk/JSTests/stress/string-overflow-createError-fit.js

    r242910 r250995  
    1313// it still fits into String::MaxLength. Check the start
    1414// of the error message.
    15 if (!exception.message.startsWith("foo is not a function"))
     15if (!exception.message.startsWith("foo is not a function")
     16    && exception != "Error: Out of memory")
    1617    throw "FAILED";
Note: See TracChangeset for help on using the changeset viewer.