Changed to more correct use of reflect.TypeOf in tests