summaryrefslogtreecommitdiff
path: root/internal/command/command_test.go
diff options
context:
space:
mode:
authorPatrick Bajao <ebajao@gitlab.com>2020-08-18 06:54:30 +0000
committerPatrick Bajao <ebajao@gitlab.com>2020-08-18 06:54:30 +0000
commitb972ea485ff85215049abe70e22f1db7242ee432 (patch)
treedd67dbef7c4c06e3a1ac5cf981be9ee37d355a03 /internal/command/command_test.go
parent4b1ee791a1bdc927becee37ae84f7ba226d17791 (diff)
parentb8d66d7923150402f54f13d793d3051efab3a832 (diff)
downloadgitlab-shell-b972ea485ff85215049abe70e22f1db7242ee432.tar.gz
Merge branch 'master' into 'master'
Add support obtaining personal access tokens via SSH See merge request gitlab-org/gitlab-shell!397
Diffstat (limited to 'internal/command/command_test.go')
-rw-r--r--internal/command/command_test.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/internal/command/command_test.go b/internal/command/command_test.go
index 2ca319e..db55e7d 100644
--- a/internal/command/command_test.go
+++ b/internal/command/command_test.go
@@ -11,6 +11,7 @@ import (
"gitlab.com/gitlab-org/gitlab-shell/internal/command/discover"
"gitlab.com/gitlab-org/gitlab-shell/internal/command/healthcheck"
"gitlab.com/gitlab-org/gitlab-shell/internal/command/lfsauthenticate"
+ "gitlab.com/gitlab-org/gitlab-shell/internal/command/personalaccesstoken"
"gitlab.com/gitlab-org/gitlab-shell/internal/command/receivepack"
"gitlab.com/gitlab-org/gitlab-shell/internal/command/shared/disallowedcommand"
"gitlab.com/gitlab-org/gitlab-shell/internal/command/twofactorrecover"
@@ -98,6 +99,12 @@ func TestNew(t *testing.T) {
arguments: []string{"key", "principal"},
expectedType: &authorizedprincipals.Command{},
},
+ {
+ desc: "it returns a PersonalAccessToken command",
+ executable: gitlabShellExec,
+ environment: buildEnv("personal_access_token"),
+ expectedType: &personalaccesstoken.Command{},
+ },
}
for _, tc := range testCases {