mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-04 23:17:50 +00:00
Make unexported fields panic (informatively)
...Also fix some incorrect calls to semantic.DeepEqual, and a bug where it returned true incorrectly.
This commit is contained in:
@@ -27,7 +27,7 @@ import (
|
||||
"net/http/httptest"
|
||||
"net/url"
|
||||
"os"
|
||||
// "reflect"
|
||||
"reflect"
|
||||
"strings"
|
||||
"testing"
|
||||
"time"
|
||||
@@ -64,7 +64,7 @@ func TestRequestWithErrorWontChange(t *testing.T) {
|
||||
if changed != &r {
|
||||
t.Errorf("returned request should point to the same object")
|
||||
}
|
||||
if !api.Semantic.DeepDerivative(changed, &original) {
|
||||
if !reflect.DeepEqual(changed, &original) {
|
||||
t.Errorf("expected %#v, got %#v", &original, changed)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user