github.com/bananabytelabs/wazero@v0.0.0-20240105073314-54b22a776da8/internal/testing/binaryencoding/element_test.go (about) 1 package binaryencoding 2 3 import ( 4 "bytes" 5 "testing" 6 7 "github.com/bananabytelabs/wazero/internal/testing/require" 8 ) 9 10 func Test_ensureElementKindFuncRef(t *testing.T) { 11 require.NoError(t, ensureElementKindFuncRef(bytes.NewReader([]byte{0x0}))) 12 require.Error(t, ensureElementKindFuncRef(bytes.NewReader([]byte{0x1}))) 13 }