mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-28 14:07:14 +00:00
Applied comments from the review
This commit is contained in:
parent
2b614179c7
commit
c02e966d65
@ -180,7 +180,7 @@ func doRoundTripTest(group testapi.TestGroup, kind string, t *testing.T) {
|
||||
if api.Scheme.Recognizes(group.GroupVersion().WithKind(kind)) {
|
||||
roundTripSame(t, group, item, nonRoundTrippableTypesByVersion[kind]...)
|
||||
}
|
||||
if !nonInternalRoundTrippableTypes.Has(kind) {
|
||||
if !nonInternalRoundTrippableTypes.Has(kind) && api.Scheme.Recognizes(group.GroupVersion().WithKind(kind)) {
|
||||
roundTrip(t, group.Codec(), fuzzInternalObject(t, group.InternalGroupVersion(), item, rand.Int63()))
|
||||
}
|
||||
}
|
||||
|
@ -75,7 +75,7 @@ func init() {
|
||||
if _, ok := Groups[autoscaling.GroupName]; !ok {
|
||||
Groups[autoscaling.GroupName] = TestGroup{
|
||||
externalGroupVersion: unversioned.GroupVersion{Group: autoscaling.GroupName, Version: registered.GroupOrDie(autoscaling.GroupName).GroupVersion.Version},
|
||||
internalGroupVersion: autoscaling.SchemeGroupVersion,
|
||||
internalGroupVersion: extensions.SchemeGroupVersion,
|
||||
}
|
||||
}
|
||||
if _, ok := Groups[extensions.GroupName]; !ok {
|
||||
|
@ -168,7 +168,6 @@ func (c *codec) Decode(data []byte, defaultGVK *unversioned.GroupVersionKind, in
|
||||
targetGV.Group = group
|
||||
targetGV.Version = runtime.APIVersionInternal
|
||||
} else {
|
||||
fmt.Printf("looking for %v in %#v\n", group, c.decodeVersion)
|
||||
gv, ok := c.decodeVersion[group]
|
||||
if !ok {
|
||||
// unknown objects are left in their original version
|
||||
|
Loading…
Reference in New Issue
Block a user