Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate resizable buffer tests out of staging #3888

Merged
merged 4 commits into from
Sep 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the only new test file in this PR that has not been added by the series of "RAB" PRs referencing this PR.

LGTM!

Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// Copyright 2023 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.

/*---
esid: sec-arraybuffer.prototype.resize
description: >
ArrayBuffer.p.resize has one detach check after argument coercion
includes: [detachArrayBuffer.js]
features: [resizable-arraybuffer]
---*/

{
const rab = new ArrayBuffer(64, { maxByteLength: 1024 });
let called = false;
assert.throws(TypeError, () => rab.resize({ valueOf() {
$DETACHBUFFER(rab);
called = true;
}}));
assert(called);
}

{
const rab = new ArrayBuffer(64, { maxByteLength: 1024 });
$DETACHBUFFER(rab);
let called = false;
assert.throws(TypeError, () => rab.resize({ valueOf() {
called = true;
}}));
assert(called);
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ includes: [compareArray.js, resizableArrayBufferUtils.js]
features: [resizable-arraybuffer]
---*/


for (let ctor of ctors) {
const rab = CreateResizableArrayBuffer(4 * ctor.BYTES_PER_ELEMENT, 8 * ctor.BYTES_PER_ELEMENT);
const fixedLength = new ctor(rab, 0, 4);
Expand Down

This file was deleted.

This file was deleted.

Loading
Loading