From 6e1c7662416792300d3627ddc995bd96eba151f5 Mon Sep 17 00:00:00 2001 From: Genevieve L'Esperance Date: Thu, 2 Sep 2021 11:24:14 -0700 Subject: [PATCH] Use getter to vet error handling in C.ObjectGet --- object_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/object_test.go b/object_test.go index 21dd8bd3..0c0de156 100644 --- a/object_test.go +++ b/object_test.go @@ -23,7 +23,7 @@ func TestObjectMethodCall(t *testing.T) { t.Errorf("unexpected value: %q", val) } - val, err = ctx.RunScript(`class Obj2 { print(str) { return str.toString() } }; new Obj2()`, "") + val, err = ctx.RunScript(`class Obj2 { print(str) { return str.toString() }; get notamethod() { throw "error" } }; new Obj2()`, "") failIf(t, err) obj, _ = val.AsObject() arg, _ := v8go.NewValue(ctx.Isolate(), "arg")