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

Compat: Test textureBindingViewDimension validation #3098

Merged

Conversation

greggman
Copy link
Contributor

Tests that if textureBindingViewDimension is incompatible with a texture's dimension in createTexture a validation error is generated

Tests that if a texture view's dimension does not match the texture's textureBindingViewDimension when passed to createBindGroup a validation error is generated.


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.

@greggman greggman requested a review from kainino0x October 26, 2023 08:07
@github-actions
Copy link

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

@greggman
Copy link
Contributor Author

greggman commented Nov 4, 2023

These pass in Chrome with the proper validating compiled in.

Copy link
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.

Sorry for the delay.

src/webgpu/compat/api/validation/createBindGroup.spec.ts Outdated Show resolved Hide resolved
src/webgpu/compat/api/validation/createBindGroup.spec.ts Outdated Show resolved Hide resolved
src/webgpu/compat/api/validation/createBindGroup.spec.ts Outdated Show resolved Hide resolved
src/webgpu/util/texture/base.ts Outdated Show resolved Hide resolved
Tests that if textureBindingViewDimension is incompatible with
a texture's dimension in createTexture a validation error is
generated

Tests that if a texture view's dimension does not match the
texture's textureBindingViewDimension when passed to createBindGroup
a validation error is generated.
@greggman greggman force-pushed the compat-texture-binding-view-dimension branch from 9a34166 to 4accd98 Compare November 7, 2023 08:41
@greggman greggman enabled auto-merge (squash) November 7, 2023 08:41
@greggman greggman merged commit 149e02a into gpuweb:main Nov 7, 2023
@greggman greggman deleted the compat-texture-binding-view-dimension branch November 7, 2023 08:50
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