@@ -24,7 +24,7 @@ func TestIssueStatus(t *testing.T) {
2424 defer jsonFile .Close ()
2525 http .StubResponse (200 , jsonFile )
2626
27- output , err := RunCommand (issueStatusCmd , "issue status" )
27+ output , err := RunCommand ("issue status" )
2828 if err != nil {
2929 t .Errorf ("error running command `issue status`: %v" , err )
3030 }
@@ -58,7 +58,7 @@ func TestIssueStatus_blankSlate(t *testing.T) {
5858 } } }
5959 ` ))
6060
61- output , err := RunCommand (issueStatusCmd , "issue status" )
61+ output , err := RunCommand ("issue status" )
6262 if err != nil {
6363 t .Errorf ("error running command `issue status`: %v" , err )
6464 }
@@ -92,7 +92,7 @@ func TestIssueStatus_disabledIssues(t *testing.T) {
9292 } } }
9393 ` ))
9494
95- _ , err := RunCommand (issueStatusCmd , "issue status" )
95+ _ , err := RunCommand ("issue status" )
9696 if err == nil || err .Error () != "the 'OWNER/REPO' repository has disabled issues" {
9797 t .Errorf ("error running command `issue status`: %v" , err )
9898 }
@@ -107,7 +107,7 @@ func TestIssueList(t *testing.T) {
107107 defer jsonFile .Close ()
108108 http .StubResponse (200 , jsonFile )
109109
110- output , err := RunCommand (issueListCmd , "issue list" )
110+ output , err := RunCommand ("issue list" )
111111 if err != nil {
112112 t .Errorf ("error running command `issue list`: %v" , err )
113113 }
@@ -143,7 +143,7 @@ func TestIssueList_withFlags(t *testing.T) {
143143 } } }
144144 ` ))
145145
146- output , err := RunCommand (issueListCmd , "issue list -a probablyCher -l web,bug -s open -A foo" )
146+ output , err := RunCommand ("issue list -a probablyCher -l web,bug -s open -A foo" )
147147 if err != nil {
148148 t .Errorf ("error running command `issue list`: %v" , err )
149149 }
@@ -183,7 +183,7 @@ func TestIssueList_nullAssigneeLabels(t *testing.T) {
183183 } } }
184184 ` ))
185185
186- _ , err := RunCommand (issueListCmd , "issue list" )
186+ _ , err := RunCommand ("issue list" )
187187 if err != nil {
188188 t .Errorf ("error running command `issue list`: %v" , err )
189189 }
@@ -211,7 +211,7 @@ func TestIssueList_disabledIssues(t *testing.T) {
211211 } } }
212212 ` ))
213213
214- _ , err := RunCommand (issueListCmd , "issue list" )
214+ _ , err := RunCommand ("issue list" )
215215 if err == nil || err .Error () != "the 'OWNER/REPO' repository has disabled issues" {
216216 t .Errorf ("error running command `issue list`: %v" , err )
217217 }
@@ -236,7 +236,7 @@ func TestIssueView_web(t *testing.T) {
236236 })
237237 defer restoreCmd ()
238238
239- output , err := RunCommand (issueViewCmd , "issue view -w 123" )
239+ output , err := RunCommand ("issue view -w 123" )
240240 if err != nil {
241241 t .Errorf ("error running command `issue view`: %v" , err )
242242 }
@@ -270,7 +270,7 @@ func TestIssueView_web_numberArgWithHash(t *testing.T) {
270270 })
271271 defer restoreCmd ()
272272
273- output , err := RunCommand (issueViewCmd , "issue view -w \" #123\" " )
273+ output , err := RunCommand ("issue view -w \" #123\" " )
274274 if err != nil {
275275 t .Errorf ("error running command `issue view`: %v" , err )
276276 }
@@ -350,7 +350,7 @@ func TestIssueView_Preview(t *testing.T) {
350350 defer jsonFile .Close ()
351351 http .StubResponse (200 , jsonFile )
352352
353- output , err := RunCommand (issueViewCmd , tc .command )
353+ output , err := RunCommand (tc .command )
354354 if err != nil {
355355 t .Errorf ("error running command `%v`: %v" , tc .command , err )
356356 }
@@ -379,7 +379,7 @@ func TestIssueView_web_notFound(t *testing.T) {
379379 })
380380 defer restoreCmd ()
381381
382- _ , err := RunCommand (issueViewCmd , "issue view -w 9999" )
382+ _ , err := RunCommand ("issue view -w 9999" )
383383 if err == nil || err .Error () != "graphql error: 'Could not resolve to an Issue with the number of 9999.'" {
384384 t .Errorf ("error running command `issue view`: %v" , err )
385385 }
@@ -401,7 +401,7 @@ func TestIssueView_disabledIssues(t *testing.T) {
401401 } } }
402402 ` ))
403403
404- _ , err := RunCommand (issueViewCmd , `issue view 6666` )
404+ _ , err := RunCommand (`issue view 6666` )
405405 if err == nil || err .Error () != "the 'OWNER/REPO' repository has disabled issues" {
406406 t .Errorf ("error running command `issue view`: %v" , err )
407407 }
@@ -426,7 +426,7 @@ func TestIssueView_web_urlArg(t *testing.T) {
426426 })
427427 defer restoreCmd ()
428428
429- output , err := RunCommand (issueViewCmd , "issue view -w https://github.com/OWNER/REPO/issues/123" )
429+ output , err := RunCommand ("issue view -w https://github.com/OWNER/REPO/issues/123" )
430430 if err != nil {
431431 t .Errorf ("error running command `issue view`: %v" , err )
432432 }
@@ -457,7 +457,7 @@ func TestIssueCreate(t *testing.T) {
457457 } } } }
458458 ` ))
459459
460- output , err := RunCommand (issueCreateCmd , `issue create -t hello -b "cash rules everything around me"` )
460+ output , err := RunCommand (`issue create -t hello -b "cash rules everything around me"` )
461461 if err != nil {
462462 t .Errorf ("error running command `issue create`: %v" , err )
463463 }
@@ -493,7 +493,7 @@ func TestIssueCreate_disabledIssues(t *testing.T) {
493493 } } }
494494 ` ))
495495
496- _ , err := RunCommand (issueCreateCmd , `issue create -t heres -b johnny` )
496+ _ , err := RunCommand (`issue create -t heres -b johnny` )
497497 if err == nil || err .Error () != "the 'OWNER/REPO' repository has disabled issues" {
498498 t .Errorf ("error running command `issue create`: %v" , err )
499499 }
@@ -511,7 +511,7 @@ func TestIssueCreate_web(t *testing.T) {
511511 })
512512 defer restoreCmd ()
513513
514- output , err := RunCommand (issueCreateCmd , `issue create --web` )
514+ output , err := RunCommand (`issue create --web` )
515515 if err != nil {
516516 t .Errorf ("error running command `issue create`: %v" , err )
517517 }
@@ -537,7 +537,7 @@ func TestIssueCreate_webTitleBody(t *testing.T) {
537537 })
538538 defer restoreCmd ()
539539
540- output , err := RunCommand (issueCreateCmd , `issue create -w -t mytitle -b mybody` )
540+ output , err := RunCommand (`issue create -w -t mytitle -b mybody` )
541541 if err != nil {
542542 t .Errorf ("error running command `issue create`: %v" , err )
543543 }
@@ -695,7 +695,7 @@ func TestIssueClose(t *testing.T) {
695695
696696 http .StubResponse (200 , bytes .NewBufferString (`{"id": "THE-ID"}` ))
697697
698- output , err := RunCommand (issueCloseCmd , "issue close 13" )
698+ output , err := RunCommand ("issue close 13" )
699699 if err != nil {
700700 t .Fatalf ("error running command `issue close`: %v" , err )
701701 }
@@ -721,7 +721,7 @@ func TestIssueClose_alreadyClosed(t *testing.T) {
721721
722722 http .StubResponse (200 , bytes .NewBufferString (`{"id": "THE-ID"}` ))
723723
724- output , err := RunCommand (issueCloseCmd , "issue close 13" )
724+ output , err := RunCommand ("issue close 13" )
725725 if err != nil {
726726 t .Fatalf ("error running command `issue close`: %v" , err )
727727 }
@@ -744,7 +744,7 @@ func TestIssueClose_issuesDisabled(t *testing.T) {
744744 } } }
745745 ` ))
746746
747- _ , err := RunCommand (issueCloseCmd , "issue close 13" )
747+ _ , err := RunCommand ("issue close 13" )
748748 if err == nil {
749749 t .Fatalf ("expected error when issues are disabled" )
750750 }
@@ -768,7 +768,7 @@ func TestIssueReopen(t *testing.T) {
768768
769769 http .StubResponse (200 , bytes .NewBufferString (`{"id": "THE-ID"}` ))
770770
771- output , err := RunCommand (issueReopenCmd , "issue reopen 2" )
771+ output , err := RunCommand ("issue reopen 2" )
772772 if err != nil {
773773 t .Fatalf ("error running command `issue reopen`: %v" , err )
774774 }
@@ -794,7 +794,7 @@ func TestIssueReopen_alreadyOpen(t *testing.T) {
794794
795795 http .StubResponse (200 , bytes .NewBufferString (`{"id": "THE-ID"}` ))
796796
797- output , err := RunCommand (issueReopenCmd , "issue reopen 2" )
797+ output , err := RunCommand ("issue reopen 2" )
798798 if err != nil {
799799 t .Fatalf ("error running command `issue reopen`: %v" , err )
800800 }
@@ -817,7 +817,7 @@ func TestIssueReopen_issuesDisabled(t *testing.T) {
817817 } } }
818818 ` ))
819819
820- _ , err := RunCommand (issueReopenCmd , "issue reopen 2" )
820+ _ , err := RunCommand ("issue reopen 2" )
821821 if err == nil {
822822 t .Fatalf ("expected error when issues are disabled" )
823823 }
0 commit comments