diff options
author | feistel <6742251-feistel@users.noreply.gitlab.com> | 2021-09-08 15:04:21 +0000 |
---|---|---|
committer | feistel <6742251-feistel@users.noreply.gitlab.com> | 2021-09-08 15:04:21 +0000 |
commit | d0e09b414a9b069ec7bcbed2880b93c27cf3727c (patch) | |
tree | 16ab2acb6bcaeb1cc88acf01f1f7f4eb9dc1ca76 /cmd/gitlab-shell/command/command_test.go | |
parent | 67415dc4f6f293460517d4281b5e4e80e66ffb91 (diff) | |
download | gitlab-shell-d0e09b414a9b069ec7bcbed2880b93c27cf3727c.tar.gz |
refactor: cleanup func signature and remove unused args
Diffstat (limited to 'cmd/gitlab-shell/command/command_test.go')
-rw-r--r-- | cmd/gitlab-shell/command/command_test.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/cmd/gitlab-shell/command/command_test.go b/cmd/gitlab-shell/command/command_test.go index 5dacb67..2db644b 100644 --- a/cmd/gitlab-shell/command/command_test.go +++ b/cmd/gitlab-shell/command/command_test.go @@ -95,7 +95,7 @@ func TestNew(t *testing.T) { for _, tc := range testCases { t.Run(tc.desc, func(t *testing.T) { - command, err := cmd.New(tc.executable, tc.arguments, tc.env, tc.config, nil) + command, err := cmd.New(tc.arguments, tc.env, tc.config, nil) require.NoError(t, err) require.IsType(t, tc.expectedType, command) @@ -125,7 +125,7 @@ func TestFailingNew(t *testing.T) { for _, tc := range testCases { t.Run(tc.desc, func(t *testing.T) { - command, err := cmd.New(tc.executable, []string{}, tc.env, basicConfig, nil) + command, err := cmd.New([]string{}, tc.env, basicConfig, nil) require.Nil(t, command) require.Equal(t, tc.expectedError, err) }) @@ -236,7 +236,7 @@ func TestParseSuccess(t *testing.T) { for _, tc := range testCases { t.Run(tc.desc, func(t *testing.T) { - result, err := cmd.Parse(tc.executable, tc.arguments, tc.env) + result, err := cmd.Parse(tc.arguments, tc.env) if !tc.expectError { require.NoError(t, err) @@ -273,7 +273,7 @@ func TestParseFailure(t *testing.T) { for _, tc := range testCases { t.Run(tc.desc, func(t *testing.T) { - _, err := cmd.Parse(tc.executable, tc.arguments, tc.env) + _, err := cmd.Parse(tc.arguments, tc.env) require.EqualError(t, err, tc.expectedError) }) |