mirror of
https://github.com/tc39/test262.git
synced 2025-07-24 22:45:10 +02:00
Fix copy-paste errors in Atomics tests
This commit is contained in:
parent
453887559d
commit
49a4e1e7c8
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.add
|
||||
esid: sec-atomics.and
|
||||
description: >
|
||||
TypedArray type is validated before `index` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.add
|
||||
esid: sec-atomics.and
|
||||
description: >
|
||||
TypedArray type is validated before `value` argument is coerced.
|
||||
info: |
|
||||
|
@ -1,7 +1,7 @@
|
||||
// Copyright (C) 2020 Rick Waldron. All rights reserved.
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
/*---
|
||||
esid: sec-atomics.compareExchange
|
||||
esid: sec-atomics.compareexchange
|
||||
description: >
|
||||
Atomics.compareExchange will operate on TA when TA.buffer is not a SharedArrayBuffer
|
||||
includes: [testBigIntTypedArray.js]
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.compareExchange
|
||||
esid: sec-atomics.compareexchange
|
||||
description: >
|
||||
Atomics.compareExchange returns the value that existed at the
|
||||
index prior to the operation.
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.compareExchange
|
||||
esid: sec-atomics.compareexchange
|
||||
description: >
|
||||
Atomics.compareExchange will operate on TA when TA.buffer is not a SharedArrayBuffer
|
||||
includes: [testTypedArray.js]
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.compareExchange
|
||||
esid: sec-atomics.compareexchange
|
||||
description: >
|
||||
Atomics.compareExchange throws when operating on non-sharable integer TypedArrays
|
||||
includes: [testTypedArray.js]
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.compareExchange
|
||||
esid: sec-atomics.compareexchange
|
||||
description: >
|
||||
TypedArray type is validated before `expectedValue` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.compareExchange
|
||||
esid: sec-atomics.compareexchange
|
||||
description: >
|
||||
TypedArray type is validated before `index` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.compareExchange
|
||||
esid: sec-atomics.compareexchange
|
||||
description: >
|
||||
TypedArray type is validated before `replacementValue` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,9 +2,9 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.add
|
||||
esid: sec-atomics.exchange
|
||||
description: >
|
||||
Atomics.add throws when operating on non-sharable integer TypedArrays
|
||||
Atomics.exchange throws when operating on non-sharable integer TypedArrays
|
||||
includes: [testTypedArray.js]
|
||||
features: [ArrayBuffer, Atomics, TypedArray]
|
||||
---*/
|
||||
@ -12,6 +12,6 @@ testWithNonAtomicsFriendlyTypedArrayConstructors(TA => {
|
||||
const buffer = new ArrayBuffer(TA.BYTES_PER_ELEMENT * 4);
|
||||
const view = new TA(buffer);
|
||||
assert.throws(TypeError, function() {
|
||||
Atomics.add(view, 0, 1);
|
||||
}, `Atomics.add(new ${TA.name}(buffer), 0, 1) throws TypeError`);
|
||||
Atomics.exchange(view, 0, 1);
|
||||
}, `Atomics.exchange(new ${TA.name}(buffer), 0, 1) throws TypeError`);
|
||||
});
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.isLockFree
|
||||
esid: sec-atomics.islockfree
|
||||
description: >
|
||||
Atomics.isLockFree returns a boolean that indicates whether
|
||||
operations on datum of size will be performed without the agent
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.store
|
||||
esid: sec-atomics.load
|
||||
description: >
|
||||
TypedArray type is validated before `index` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,9 +2,9 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.and
|
||||
esid: sec-atomics.or
|
||||
description: >
|
||||
Atomics.and throws when operating on non-sharable integer TypedArrays
|
||||
Atomics.or throws when operating on non-sharable integer TypedArrays
|
||||
includes: [testTypedArray.js]
|
||||
features: [ArrayBuffer, Atomics, TypedArray]
|
||||
---*/
|
||||
@ -13,6 +13,6 @@ testWithNonAtomicsFriendlyTypedArrayConstructors(TA => {
|
||||
const view = new TA(buffer);
|
||||
|
||||
assert.throws(TypeError, function() {
|
||||
Atomics.and(view, 0, 1);
|
||||
}, `Atomics.and(new ${TA.name}(buffer), 0, 1) throws TypeError`);
|
||||
Atomics.or(view, 0, 1);
|
||||
}, `Atomics.or(new ${TA.name}(buffer), 0, 1) throws TypeError`);
|
||||
});
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.notify
|
||||
esid: sec-atomics.wait
|
||||
description: >
|
||||
TypedArray type is validated before `timeout` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.notify
|
||||
esid: sec-atomics.wait
|
||||
description: >
|
||||
TypedArray type is validated before `value` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,7 +2,7 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.notify
|
||||
esid: sec-atomics.waitasync
|
||||
description: >
|
||||
TypedArray type is validated before `value` argument is coerced.
|
||||
info: |
|
||||
|
@ -2,9 +2,9 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.and
|
||||
esid: sec-atomics.xor
|
||||
description: >
|
||||
Atomics.and will operate on TA when TA.buffer is not a SharedArrayBuffer
|
||||
Atomics.xor will operate on TA when TA.buffer is not a SharedArrayBuffer
|
||||
includes: [testTypedArray.js]
|
||||
features: [ArrayBuffer, Atomics, TypedArray]
|
||||
---*/
|
||||
@ -13,6 +13,6 @@ testWithAtomicsFriendlyTypedArrayConstructors(TA => {
|
||||
new ArrayBuffer(TA.BYTES_PER_ELEMENT * 4)
|
||||
);
|
||||
|
||||
assert.sameValue(Atomics.and(view, 0, 1), 0, 'Atomics.and(view, 0, 1) returns 0');
|
||||
assert.sameValue(Atomics.load(view, 0), 0, 'Atomics.load(view, 0) returns 0');
|
||||
assert.sameValue(Atomics.xor(view, 0, 1), 0, 'Atomics.xor(view, 0, 1) returns 0');
|
||||
assert.sameValue(Atomics.load(view, 0), 1, 'Atomics.load(view, 0) returns 1');
|
||||
});
|
||||
|
@ -2,9 +2,9 @@
|
||||
// This code is governed by the BSD license found in the LICENSE file.
|
||||
|
||||
/*---
|
||||
esid: sec-atomics.and
|
||||
esid: sec-atomics.xor
|
||||
description: >
|
||||
Atomics.and throws when operating on non-sharable integer TypedArrays
|
||||
Atomics.xor throws when operating on non-sharable integer TypedArrays
|
||||
includes: [testTypedArray.js]
|
||||
features: [ArrayBuffer, Atomics, TypedArray]
|
||||
---*/
|
||||
@ -13,6 +13,6 @@ testWithNonAtomicsFriendlyTypedArrayConstructors(TA => {
|
||||
const view = new TA(buffer);
|
||||
|
||||
assert.throws(TypeError, function() {
|
||||
Atomics.and(view, 0, 1);
|
||||
}, `Atomics.and(new ${TA.name}(buffer), 0, 1) throws TypeError`);
|
||||
Atomics.xor(view, 0, 1);
|
||||
}, `Atomics.xor(new ${TA.name}(buffer), 0, 1) throws TypeError`);
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user