summaryrefslogtreecommitdiff
path: root/go/internal/command/fallback/fallback_test.go
diff options
context:
space:
mode:
authorPatrick Bajao <ebajao@gitlab.com>2019-07-29 15:56:00 +0800
committerPatrick Bajao <ebajao@gitlab.com>2019-07-31 12:03:37 +0800
commit3b0176df497263323da2fae793a79b568502e6db (patch)
treef4ff3e232bc3717c539d73a4f0460d6d12b4a6de /go/internal/command/fallback/fallback_test.go
parentaab85f3600caf04b491d6ca4fc3f0f004d9e3fc0 (diff)
downloadgitlab-shell-3b0176df497263323da2fae793a79b568502e6db.tar.gz
Support different CommandArgs type
`CommandArgs` has been renamed to `Shell`. An interface has been added that includes `Executable()` and `Arguments()` method. The `BaseArgs` implement this methods and should be embeeded in each type.
Diffstat (limited to 'go/internal/command/fallback/fallback_test.go')
-rw-r--r--go/internal/command/fallback/fallback_test.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/go/internal/command/fallback/fallback_test.go b/go/internal/command/fallback/fallback_test.go
index 91dcb53..669aad1 100644
--- a/go/internal/command/fallback/fallback_test.go
+++ b/go/internal/command/fallback/fallback_test.go
@@ -25,6 +25,11 @@ type FakeCommandArgs struct {
arguments []string
}
+func (f *FakeCommandArgs) Parse() error {
+ // Do nothing as no need to parse anything
+ return nil
+}
+
func (f *FakeCommandArgs) Executable() commandargs.Executable {
return f.executable
}