Skip to content

Test buffer.mapAsync() early rejection#2033

Merged
kainino0x merged 1 commit intogpuweb:mainfrom
takahirox:EarlyRejectMapAsync
Nov 29, 2022
Merged

Test buffer.mapAsync() early rejection#2033
kainino0x merged 1 commit intogpuweb:mainfrom
takahirox:EarlyRejectMapAsync

Conversation

@takahirox
Copy link
Copy Markdown
Contributor

@takahirox takahirox commented Nov 26, 2022

With this WebGPU spec change gpuweb/gpuweb#3348 buffer.mapAsync() rejects immediately if it is pending map. This commit adds a test to check it.

The test is based on https://bugs.chromium.org/p/chromium/issues/detail?id=1355994#c3 that @kainino0x suggested.

Issue: #2009


Requirements for PR author:

  • All missing test coverage is tracked with "TODO" or .unimplemented().
  • New helpers are /** documented */ and new helper files are found in helper_index.txt.
  • Test behaves as expected in a WebGPU implementation. (If not passing, explain above.)

Requirements for reviewer sign-off:

  • Tests are properly located in the test tree.
  • Test descriptions allow a reader to "read only the test plans and evaluate coverage completeness", and accurately reflect the test code.
  • Tests provide complete coverage (including validation control cases). Missing coverage MUST be covered by TODOs.
  • Helpers and types promote readability and maintainability.

When landing this PR, be sure to make any necessary issue status updates.

With this WebGPU spec change
gpuweb/gpuweb#3348

buffer.mapAsync() rejects immediately if it is pending map.
This commit adds a test to check it.
@github-actions
Copy link
Copy Markdown

Previews, as seen when this build job started (f831bef):
Run tests | View tsdoc

Copy link
Copy Markdown
Collaborator

@kainino0x kainino0x left a comment

Choose a reason for hiding this comment

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

LGTM! Left a note on #2009 about adding a bit more rigor to the other tests.

@kainino0x kainino0x merged commit 40abc04 into gpuweb:main Nov 29, 2022
@takahirox takahirox deleted the EarlyRejectMapAsync branch November 29, 2022 01:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants