From 447b667c873f09ea9256666769abd6be7c40ae5b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Beaufort?= Date: Wed, 6 Nov 2024 22:52:31 +0100 Subject: [PATCH] Assert GPUAdapterInfo instances (#4034) --- src/webgpu/api/operation/adapter/info.spec.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/webgpu/api/operation/adapter/info.spec.ts b/src/webgpu/api/operation/adapter/info.spec.ts index 89dbbaa621f2..4fef9a56ddf7 100644 --- a/src/webgpu/api/operation/adapter/info.spec.ts +++ b/src/webgpu/api/operation/adapter/info.spec.ts @@ -51,6 +51,7 @@ but different objects from one another.` const gpu = getGPU(t.rec); const adapter = await gpu.requestAdapter(); assert(adapter !== null); + assert(adapter.info instanceof GPUAdapterInfo); const adapterInfo1 = adapter.info; const adapterInfo2 = adapter.info; @@ -58,6 +59,7 @@ but different objects from one another.` const device = await t.requestDeviceTracked(adapter); assert(device !== null); + assert(device.adapterInfo instanceof GPUAdapterInfo); const deviceAdapterInfo1 = device.adapterInfo; const deviceAdapterInfo2 = device.adapterInfo;