blob: 845c3cbd44f58f8de037354df6380c2b78662309 [file] [log] [blame]
package androidx.webgpu
import org.junit.Assert.assertEquals
import org.junit.Test
class StructuresTest {
@Test
fun defaultZeroTest() {
val bindingLayoutEntry = GPUBindGroupLayoutEntry(binding = 0, visibility = ShaderStage.Vertex)
assertEquals("default=zero member structures not initializing enums to their zero value",
SamplerBindingType.BindingNotUsed, bindingLayoutEntry.sampler.type)
}
@Test
fun defaultTest() {
val sampler = GPUSamplerBindingLayout()
assertEquals("Non-defaulted structure not initialized enum to IDL-specified default",
SamplerBindingType.Filtering, sampler.type)
}
}