mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-17 15:50:10 +00:00
Update test to track status prefix on paths
This commit is contained in:
parent
793ac57e5a
commit
0a10014162
@ -595,8 +595,9 @@ func TestValidateOnlyStatus(t *testing.T) {
|
|||||||
if !isStatus || statusError == nil {
|
if !isStatus || statusError == nil {
|
||||||
t.Fatalf("expected status error, got %T: %v", err, err)
|
t.Fatalf("expected status error, got %T: %v", err, err)
|
||||||
}
|
}
|
||||||
if !strings.Contains(statusError.Error(), "Invalid value") {
|
expectedErr := "WishIHadChosenNoxu.mygroup.example.com \"foo\" is invalid: status.num: Invalid value: 15: num in body should be less than or equal to 10"
|
||||||
t.Fatalf("expected 'Invalid value' in error, got: %v", err)
|
if !strings.Contains(statusError.Error(), expectedErr) {
|
||||||
|
t.Fatalf("expected %q in error, got: %v", expectedErr, err)
|
||||||
}
|
}
|
||||||
noxuResourceClient.Delete(context.TODO(), "foo", metav1.DeleteOptions{})
|
noxuResourceClient.Delete(context.TODO(), "foo", metav1.DeleteOptions{})
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user