core/tracing: remove unnecessary 'copy' field skip in TestAllHooksCalled (#32622)

This test iterated over Hooks fields and skipped a field named copy. The
Hooks struct has no such field, making the condition dead code.
This commit is contained in:
VolodymyrBg 2025-09-16 14:58:37 +03:00 committed by GitHub
parent e48242bb69
commit b340103e9d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -280,10 +280,6 @@ func TestAllHooksCalled(t *testing.T) {
if field.Type.Kind() != reflect.Func {
continue
}
// Skip non-hooks, i.e. Copy
if field.Name == "copy" {
continue
}
// Skip if field is not set
if wrappedValue.Field(i).IsNil() {
continue