Commit Graph

6744 Commits

Author SHA1 Message Date
Ms2ger 941813e1f0 Revert "Revert "Add invalid index Reflect.set tests""
This reverts commit b110681292.
2024-08-16 17:26:15 +02:00
Ms2ger 79faa2252a Revert "Revert "Add invalid index prototype chain [[Set]] tests""
This reverts commit 3d77404e4f.
2024-08-16 17:26:15 +02:00
Ms2ger 44685c14d7 Revert "Revert "Add valid index Reflect.set tests""
This reverts commit b90326d9a4.
2024-08-16 17:26:15 +02:00
Ms2ger efa4272ffb Revert "Revert "Add valid index prototype chain [[Set]] tests""
This reverts commit bd65623af6.
2024-08-16 17:26:15 +02:00
Ioanna M Dimitriou H 224c5c3cb9
RAB: Integrate staging tests for the .subarray method (#4177)
* Import relevant files from #3888

* Adds resizableArrayBufferUtils.js to includes and removes its content from each test

* renamed tests to indicate the end argument is tested too

* Adds more tests for the 'end' argument of .subarray
2024-08-15 15:13:34 -07:00
Philip Chimento cb4a6c8074 Temporal: Add a test for a coverage gap in Duration.prototype.round
See https://github.com/tc39/proposal-temporal/issues/2919; this adds test
coverage that would have caught an unintentional normative change.
2024-08-15 10:26:58 +02:00
Ioanna M Dimitriou H b1d0933df5
RAB: Integrate staging tests for the .toLocaleString method (#4178)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while applying review changes from PRs for previously tested methods.

* Apply suggestions from code review

* Address review: get implementation dependent toLocaleString separator.

* Apply suggestions from code review
2024-08-14 12:30:54 -07:00
Linus Groh 984df1f3db Remove unused harness/timer.js 2024-08-14 08:37:46 -07:00
Ioanna M Dimitriou H 12307f5c20
RAB: Integrate staging tests for the .slice method (#4174)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while applying review changes from PRs for previously tested methods.

* Add coerced-start-shrink test for Array.p.slice

* Renames files to add more tests for the end argument of .slice.

* Tests for the 'end' argument of .slice and test file for Array.p.slice
parallel to TypedArray.p.slice resizable-buffer.js
2024-08-13 17:03:51 -07:00
Chengzhong Wu 7608bfb146 Update INTERPRETING.md fixing `$262.AbstractModuleSource` position 2024-08-13 11:25:59 -07:00
Luis Fernando Pardo Sixtos 2020cfbe66 [decorators] Support private auto-accessors
Support for the accessor keywords for private class fields as part of
the decorators proposal.

Changes to AST:

- Add an AUTO_ACCESSOR value to the ClassLiteralProperty::Kind enum.
- Add an AutoAccessorInfo class to be used in ClassLiteralProperty
  objects of kind AUTO_ACCESSOR to hold the information about the
  generated getters/setters and backing storage.
- Add AutoAccessorGetterBody and AutoAccessorSetterBody statements to
  implement the logic of generated getters and setters.

Changes to Parser:
- Add logic to parse the "accessor" keyword and throw when used on non
  field class properties.
- Add preparser logic to mock the function scopes and variable
  declarations required for the generated getters/setters.
- Add parser logic to synthetically create statements for the
  generated setters/getters. 

Changes to the Bytecode Generator:
- Add logic to BuildClassLiteral to build auto accessor storage
  private names.
- Add logic to set the generated getters/setters in the accessor pair.
- Add logic to initialize the accessor storage in BuildClassProperty.
- Add AutoAccessorGetterBody and AutoAccessorSetterBody visitors.

Tests:
- Add parsing-unittests for parsing converage.
- Add test262 tests for functionality coverage.
- Add test-debug test for devtools support coverage.

Bug: 42202709
Change-Id: Ibb9bee3bbd0c09341108856f969e0c22bbb8b9cc
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5547688
Reviewed-by: Seth Brenith <seth.brenith@microsoft.com>
Commit-Queue: Luis Pardo <lpardosixtos@microsoft.com>
Reviewed-by: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#95612}
2024-08-13 19:35:08 +02:00
Ioanna M Dimitriou H bcb42e339d
RAB: Integrate staging tests for the .some method (#4175)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while applying review changes from PRs for previously tested methods.

* Address review comments.
2024-08-09 09:05:04 -07:00
Marko Lahma 5dc04b7332 Fix TypedArray.reduce tests against RAB
* reduce callback has call signature «accumulator, kValue, 𝔽(k), O »
2024-08-06 15:15:19 -07:00
Ioanna M Dimitriou H dc36c7eae9
RAB: Integrate staging tests for the .values method (#4179)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while applying review changes from PRs for previously tested methods.

* Removes unnecessary .from calls, as suggested in previous PR review
comment: https://github.com/tc39/test262/pull/4138#discussion_r1676183221
2024-08-05 17:26:21 -07:00
Ioanna M Dimitriou H ef72bd1c44
RAB: Integrate staging tests for the .sort method (#4176)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while applying review changes from PRs for previously tested methods.

* Renamed test files

* Some minor documentation fixes and removing onlyStrict flag
2024-08-05 17:22:10 -07:00
Ioanna M Dimitriou H c0942e0883
RAB: Integrate staging tests for the .set method (#4173)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
and renaming helper function.
2024-08-05 14:09:41 -07:00
Aurèle ea37a19a4a
Add tests for nullable quantifiers in RegExps (#4185)
* Add tests for nullable quantifiers in RegExps

The JavaScript semantics for a quantifier matching the empty
string are different from other regex languages.
This adds a test that documents this JavaScript-specific
behavior.

This is part of my work at the SYSTEMF lab at EPFL.

* Update nullable-quantifier.js
2024-08-05 13:02:50 -07:00
Richard Gibson feb400c685 harness/asyncHelpers.js: Update throwsAsync to not succeed on a bad thenable
Fixes #4186
2024-08-02 08:52:05 +02:00
Richard Gibson 7a916718cf
Cleanup asyncHelpers (merge #4091) 2024-08-01 12:21:00 -04:00
Richard Gibson f83c1b9387 harness/asyncHelpers.js: Further reduce the size of assert.throwsAsync 2024-08-01 12:10:32 -04:00
Richard Gibson fa3d0246e7 harness/asyncHelpers.js: Reduce the size of assert.throwsAsync 2024-08-01 11:42:34 -04:00
Richard Gibson 0b61e98564 harness/asyncHelpers.js: Clean up assert.throwsAsync failure messages
* Remove mention of an "inner" promise/thenable.
2024-08-01 11:41:25 -04:00
Richard Gibson b87eaf9ac3 harness/asyncHelpers.js: Fix an assert.throwsAsync failure message typo 2024-08-01 11:39:10 -04:00
Richard Gibson 0631e2111b harness/asyncHelpers.js: Isolate assert.throwsAsync failure conditions 2024-08-01 11:38:06 -04:00
Richard Gibson b22b500f24 harness/asyncHelpers.js: Refactor assert.throwsAsync to fail fast 2024-08-01 11:38:06 -04:00
Richard Gibson 1b34a1c484 harness/asyncHelpers.js: Add doc comments 2024-08-01 11:38:06 -04:00
Richard Gibson 8ca5bdd44c CONTRIBUTING.md: Improve asyncHelpers documentation
* Only mention `$DONE` after `asyncTest`.
* Document that `asyncTest` is not intended to be called multiple times per file.
2024-08-01 11:38:06 -04:00
Lucas Mirelmann 5492929d55 Fix typo
Fix typo in an ObjectLiteral
2024-08-01 16:06:56 +02:00
Sosuke Suzuki 616dcadff4 Fix escaped `a` 2024-07-30 10:01:51 +02:00
Ioanna M Dimitriou H 1842afcbce
RAB: Integrate staging tests for the .reduce method (#4156)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while adjusting usage of CollectValuesAndResize and applying review changes
from PRs for previously tested methods.

* Added missing 'shrink' test for Array.prototype.reduce

* Deleted accidental files

* Fix accidental call of .map instead of .reduce

Addresses review comments

* fix copyright in new file not in origin PR
2024-07-29 17:33:50 -07:00
Ioanna M. Dimitriou H 6add1a22cd adds features: [explicit-resource-management] flag 2024-07-29 16:31:26 -07:00
Ioanna M. Dimitriou H e612296c41 Changed two files to use verifyProperty. 2024-07-29 16:31:26 -07:00
Ioanna M. Dimitriou H 435a89b702 Address review comments and fixes some more descriptions
- Fixes to two tests testing Map.prototype.size
- Description fixes
2024-07-29 16:31:26 -07:00
Ron Buckton cb8324fdba Adds [is/not]-a-constructor.js tests from @rbuckton's PR #3866
to make reviewing easier.
2024-07-29 16:31:26 -07:00
Ron Buckton c916d81d85 Adds .length property descriptor tests for explicit resource management
These are all the length.js tests from @rbuckton's PR #3866 to make reviewing easier.
2024-07-29 16:31:26 -07:00
Ron Buckton 59657217f1 Adds .name property descriptor tests for explicit resource management
These are all the name.js tests from @rbuckton's PR #3866 to make reviewing easier.
2024-07-29 16:31:26 -07:00
Ioanna M. Dimitriou H 8996664a42 Added expected esid's 2024-07-29 16:31:26 -07:00
Ron Buckton 3a615a0c0e Adds property descriptor tests for explicit resource management objects
These are all the prop-desc.js tests from @rbuckton's PR #3866 to make reviewing easier.
2024-07-29 16:31:26 -07:00
Philip Chimento 3b89be9c5d Temporal: Fix Japanese era test
This mistakenly used a previous name for the helper function. Also adds
a couple of debugging messages.
2024-07-29 14:17:24 +02:00
Ioanna M Dimitriou H 242f6f98f0
RAB: Integrate staging tests for the .map method (#4155)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while adjusting usage of CollectValuesAndResize and applying review changes
from PRs for previously tested methods.

* Apply suggestions from code review
2024-07-25 16:04:41 -07:00
André Bargull 7f81bb2126 Allow canonical era codes for Japanese era test 2024-07-25 11:59:15 -07:00
André Bargull a238ad6a1e Move test for dates before start of the Japanese era into a new file
See also <https://github.com/tc39/proposal-temporal/issues/2865>
requesting for more information how this case should actually be
handled.
2024-07-25 11:59:15 -07:00
André Bargull dcaed0523c Allow implementation-defined behaviour for constraining leap months 2024-07-25 11:46:15 -07:00
Paul Bakker e7d9c0d698 Follow-up to #4165
Added catch to achieve the entire goal of the previous PR to prevent the
harness from loading if 'class' syntax isn't supported
2024-07-25 09:29:40 -07:00
Ioanna M Dimitriou H 18ebac8122
RAB: Integrate staging tests for the .reverse method (#4160)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while adjusting usage of CollectValuesAndResize and applying review changes
from PRs for previously tested methods.
2024-07-24 16:55:16 -07:00
Ioanna M Dimitriou H 1dd1b91d14
RAB: Integrate staging tests for the .reduceRight method (#4157)
* Import relevant files from #3888

* Removing parts in resizableArrayBufferUtils.js and adding it in includes,
while adjusting usage of CollectValuesAndResize and applying review changes
from PRs for previously tested methods.

* Added missing 'shrink' test for Array.prototype.reduceRight
2024-07-24 16:39:27 -07:00
Frank Tang 12416e0fa9 Add tests for DurationFormat PR 172 and 167
Test the order of resolvedOptions in default setting
Also add test to check the reading order of options based on the
property returned in the default setting resolvedOptions.

https://github.com/tc39/proposal-intl-duration-format/pull/167
https://github.com/tc39/proposal-intl-duration-format/pull/172
https://tc39.es/proposal-intl-duration-format/#sec-Intl.DurationFormat.prototype.resolvedOptions

These two PRs are presenting to TC39 2023-09 meeting

Swap actual/expected order

Update test/intl402/DurationFormat/constructor-option-read-order.js

Co-authored-by: André Bargull <andre.bargull@gmail.com>

Fix per anba suggestion
2024-07-24 15:47:38 -07:00
Paul Bakker 79df6ec2e1 Make resizableArrayBufferUtils not depend on syntax that may not be
supported
2024-07-24 12:52:18 -07:00
Paul Bakker b6c2f55954 Remove unneeded /u flag within harness/nativeFunctionMatcher 2024-07-24 10:46:30 -07:00
Philip Chimento 50b023e6c9
Fix syntax error from #4164 (#4167)
* Fix syntax error from #4164

Function statements require a name.

See #4166

* Apply suggestions from code review

Co-authored-by: Jordan Harband <ljharb@gmail.com>

---------

Co-authored-by: Jordan Harband <ljharb@gmail.com>
2024-07-24 10:29:51 -07:00