mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-03 18:27:49 +00:00
kubectl/config/rename: fix wording
Using "Context %q renamed to %q." in rename-context to be consistent with other commands like delete-context, set-context, use-context. Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
This commit is contained in:
@@ -130,6 +130,6 @@ func (o RenameContextOptions) RunRenameContext(out io.Writer) error {
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
fmt.Fprintf(out, "Context %q was renamed to %q.\n", o.contextName, o.newName)
|
fmt.Fprintf(out, "Context %q renamed to %q.\n", o.contextName, o.newName)
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
@@ -62,7 +62,7 @@ func TestRenameContext(t *testing.T) {
|
|||||||
initialConfig: initialConfig,
|
initialConfig: initialConfig,
|
||||||
expectedConfig: expectedConfig,
|
expectedConfig: expectedConfig,
|
||||||
args: []string{currentContext, newContext},
|
args: []string{currentContext, newContext},
|
||||||
expectedOut: fmt.Sprintf("Context %q was renamed to %q.\n", currentContext, newContext),
|
expectedOut: fmt.Sprintf("Context %q renamed to %q.\n", currentContext, newContext),
|
||||||
expectedErr: "",
|
expectedErr: "",
|
||||||
}
|
}
|
||||||
test.run(t)
|
test.run(t)
|
||||||
|
Reference in New Issue
Block a user