diff --git a/command/pr_test.go b/command/pr_test.go index 88eb6f2a8..6d5bf8869 100644 --- a/command/pr_test.go +++ b/command/pr_test.go @@ -89,18 +89,6 @@ func TestPRView(t *testing.T) { } } -type outputStub struct { - contents []byte -} - -func (s outputStub) Output() ([]byte, error) { - return s.contents, nil -} - -func (s outputStub) Run() error { - return nil -} - func TestPRView_NoActiveBranch(t *testing.T) { initBlankContext("OWNER/REPO", "master") http := initFakeHTTP() diff --git a/command/testing.go b/command/testing.go new file mode 100644 index 000000000..3d7284d23 --- /dev/null +++ b/command/testing.go @@ -0,0 +1,14 @@ +package command + +// outputStub implements a simple utils.Runnable +type outputStub struct { + output []byte +} + +func (s outputStub) Output() ([]byte, error) { + return s.output, nil +} + +func (s outputStub) Run() error { + return nil +}