Rename 'vpn firewall list' to 'vpn firewall show'

This commit is contained in:
Brian Picciano 2024-12-10 13:55:03 +01:00
parent cf968ff883
commit a5829a6493
2 changed files with 6 additions and 6 deletions

View File

@ -159,9 +159,9 @@ func newFirewallView(firewallConfig daecommon.ConfigFirewall) firewallView {
} }
} }
var subCmdVPNFirewallList = subCmd{ var subCmdVPNFirewallShow = subCmd{
name: "list", name: "show",
descr: "List all currently configured firewall rules", descr: "Shows the currently configured firewall rules",
do: doWithOutput(func(ctx subCmdCtx) (any, error) { do: doWithOutput(func(ctx subCmdCtx) (any, error) {
staged := ctx.flags.Bool( staged := ctx.flags.Bool(
"staged", "staged",
@ -201,7 +201,7 @@ var subCmdVPNFirewall = subCmd{
do: func(ctx subCmdCtx) error { do: func(ctx subCmdCtx) error {
return ctx.doSubCmd( return ctx.doSubCmd(
subCmdVPNFirewallAdd, subCmdVPNFirewallAdd,
subCmdVPNFirewallList, subCmdVPNFirewallShow,
) )
}, },
} }

View File

@ -160,7 +160,7 @@ func TestVPNFirewallAdd(t *testing.T) {
} }
} }
func TestVPNFirewallList(t *testing.T) { func TestVPNFirewallShow(t *testing.T) {
t.Parallel() t.Parallel()
tests := []struct { tests := []struct {
@ -323,7 +323,7 @@ func TestVPNFirewallList(t *testing.T) {
Once() Once()
} }
args := append([]string{"vpn", "firewall", "list"}, test.flags...) args := append([]string{"vpn", "firewall", "show"}, test.flags...)
if test.wantErr == "" { if test.wantErr == "" {
h.runAssertStdout(t, test.want, args...) h.runAssertStdout(t, test.want, args...)