Skip to content

Commit

Permalink
fix requestAdapter test.
Browse files Browse the repository at this point in the history
Sorry, the PR was old. Needed updating for the latest API
  • Loading branch information
greggman committed Dec 15, 2022
1 parent 5a5838d commit 17522c8
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/webgpu/api/operation/adapter/requestAdapter.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,15 @@ async function testAdapter(adapter: GPUAdapter | null) {
assert(device !== null, 'Failed to get device.');

const kOffset = 1230000;
const pipeline = await device.createComputePipeline({
const pipeline = device.createComputePipeline({
layout: 'auto',
compute: {
module: device.createShaderModule({
code: `
struct Buffer { data: array<u32>; };
struct Buffer { data: array<u32>, };
@group(0) @binding(0) var<storage, read_write> buffer: Buffer;
@stage(compute) @workgroup_size(1u) fn main(
@compute @workgroup_size(1u) fn main(
@builtin(global_invocation_id) id: vec3<u32>) {
buffer.data[id.x] = id.x + ${kOffset}u;
}
Expand Down

0 comments on commit 17522c8

Please sign in to comment.