tc39 / test262

Official ECMAScript Conformance Test Suite
Other
2.38k stars 461 forks source link

Collection of helper constants and functions for testing RABs #4030

Closed ioannad closed 6 months ago

ioannad commented 7 months ago

These are the parts of the code in resizable array buffer staging tests that are heavily repeated. In order to somewhat compact the migration of RAB staging tests (see PR #3888).

ioannad commented 6 months ago

@ptomato @ljharb I think this is now ready for another round of reviews. I think everything is addressed except the name of the argument ta to TestIterationAndResize. Indeed "test array" seems to be the intended meaning as you said Philip, but it could also be a leftover from initial tests where the typed array - named also ta in the test files - was used instead of the derived arrays and iterators that are used there now.

ioannad commented 6 months ago

@ljharb just a friendly ping since my previous comment is now marked outdated:

WDYT about leaving the for-of loop in TestIterationAndResize? If you are ok with keeping the for-of loop after all, then I think all the other review comments have been addressed and this is ready to get merged.

ljharb commented 6 months ago

I certainly won't block on it, it's just nice if tests don't rely on syntax that isn't necessary to run the test :-)

ptomato commented 6 months ago

OK, let's move forward with this. If there's an opportunity to get rid of the for-of by not using iterables elsewhere, I'd be happy to merge it in the future, but the RAB tests have been waiting for long enough :smile: