From a038a33dcfb71ae52f829a70d9a6e843ce9b074b Mon Sep 17 00:00:00 2001 From: ialidzhikov Date: Wed, 15 Jan 2020 11:34:27 +0200 Subject: [PATCH] Clean up commented assertions in tests Signed-off-by: ialidzhikov --- pkg/api/testing/serialization_test.go | 4 ---- staging/src/k8s.io/apimachinery/pkg/runtime/scheme_test.go | 4 ---- 2 files changed, 8 deletions(-) diff --git a/pkg/api/testing/serialization_test.go b/pkg/api/testing/serialization_test.go index ba6d1c1ea9f..68209f2985c 100644 --- a/pkg/api/testing/serialization_test.go +++ b/pkg/api/testing/serialization_test.go @@ -292,10 +292,6 @@ func TestBadJSONRejection(t *testing.T) { if _, err1 := runtime.Decode(legacyscheme.Codecs.LegacyCodec(v1.SchemeGroupVersion), badJSONUnknownType); err1 == nil { t.Errorf("Did not reject despite use of unknown type: %s", badJSONUnknownType) } - /*badJSONKindMismatch := []byte(`{"kind": "Pod"}`) - if err2 := DecodeInto(badJSONKindMismatch, &Node{}); err2 == nil { - t.Errorf("Kind is set but doesn't match the object type: %s", badJSONKindMismatch) - }*/ } // TestUnversionedTypes establishes that the default codec can encode and diff --git a/staging/src/k8s.io/apimachinery/pkg/runtime/scheme_test.go b/staging/src/k8s.io/apimachinery/pkg/runtime/scheme_test.go index e53765bd3e9..260d211f498 100644 --- a/staging/src/k8s.io/apimachinery/pkg/runtime/scheme_test.go +++ b/staging/src/k8s.io/apimachinery/pkg/runtime/scheme_test.go @@ -263,10 +263,6 @@ func TestBadJSONRejection(t *testing.T) { if _, err1 := runtime.Decode(jsonserializer, badJSONUnknownType); err1 == nil { t.Errorf("Did not reject despite use of unknown type: %s", badJSONUnknownType) } - /*badJSONKindMismatch := []byte(`{"kind": "Pod"}`) - if err2 := DecodeInto(badJSONKindMismatch, &Node{}); err2 == nil { - t.Errorf("Kind is set but doesn't match the object type: %s", badJSONKindMismatch) - }*/ } func TestExternalToInternalMapping(t *testing.T) {