Commit 4550cdf5 authored by Igor Sheludko's avatar Igor Sheludko Committed by Commit Bot

[test] Update TypedArray tests

... that started failing on AIX where the allocation of a huge
ArrayBuffer succeeds.

Bug: v8:4153
Change-Id: I322c71e01edccb254a523f7f85817971b6c68242
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1914561Reviewed-by: 's avatarToon Verwaest <verwaest@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#64960}
parent e8f6e384
......@@ -27,7 +27,8 @@ function TestArrayBufferCreation() {
assertThrows(function() { new ArrayBuffer(-2.567); }, RangeError);
assertThrows(function() {
var ab1 = new ArrayBuffer(0xFFFFFFFFFFFF)
let kArrayBufferByteLengthLimit = %ArrayBufferMaxByteLength() + 1;
var ab1 = new ArrayBuffer(kArrayBufferByteLengthLimit);
}, RangeError);
var ab = new ArrayBuffer();
......
......@@ -47,7 +47,8 @@ function TestArrayBufferCreation() {
assertThrows(function() { new ArrayBuffer(-2.567); }, RangeError);
assertThrows(function() {
var ab1 = new ArrayBuffer(0xFFFFFFFFFFFF)
let kArrayBufferByteLengthLimit = %ArrayBufferMaxByteLength() + 1;
var ab1 = new ArrayBuffer(kArrayBufferByteLengthLimit);
}, RangeError);
var ab = new ArrayBuffer();
......
......@@ -25,8 +25,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
// Flags: --harmony-sharedarraybuffer
// Flags: --harmony-sharedarraybuffer --allow-natives-syntax
// SharedArrayBuffer
......@@ -48,7 +47,8 @@ function TestArrayBufferCreation() {
assertThrows(function() { new SharedArrayBuffer(-2.567); }, RangeError);
assertThrows(function() {
var ab1 = new SharedArrayBuffer(0xFFFFFFFFFFFF)
let kArrayBufferByteLengthLimit = %ArrayBufferMaxByteLength() + 1;
var ab1 = new SharedArrayBuffer(kArrayBufferByteLengthLimit);
}, RangeError);
var sab = new SharedArrayBuffer();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment