Corey Johnson
f2afbbce74
Fix test output
2019-12-20 12:07:53 -08:00
Corey Johnson
58761a8dfc
Fix tests
2019-12-20 12:04:23 -08:00
Corey Johnson
8f74b658b2
Merge remote-tracking branch 'origin/master' into appropriate-context-and-feedback
2019-12-20 11:51:37 -08:00
Corey Johnson
bcf1f98702
Do a better job of reverting test changes
2019-12-20 11:32:27 -08:00
Corey Johnson
d025d2d4f3
Revert test changes
2019-12-20 11:24:03 -08:00
Corey Johnson
b66c34e0ec
Output to stderr
2019-12-20 11:16:27 -08:00
Corey Johnson
b98bd2cfb8
Use base branch
2019-12-20 10:58:25 -08:00
Mislav Marohnić
9c36c7bae9
Ensure that string flags are reset between test runs
2019-12-20 13:17:02 +01:00
Mislav Marohnić
00cede9e5f
Fix issue list re: issues that have an assignee
...
Given the GraphQL query:
issues(filterBy: {assignee: $assignee})
It turns out that passing a query variable `"assignee": null` is NOT
equivalent to omitting the variable altogether:
- `"assignee": null` seems to filter out issues that HAVE an assignee;
- omitting `assignee` correctly returns all issues.
2019-12-20 13:07:11 +01:00
Nate Smith
ade69a403c
Merge pull request #178 from github/issues-disabled
...
Warn about repo issues disabled on `issue status/list/create`
2019-12-19 15:39:07 -06:00
Nate Smith
58a6cbc46e
Merge pull request #179 from github/pr-checks-test
...
Add tests for `pr status` reviews, checks, and blank slate output
2019-12-19 15:33:06 -06:00
Nate Smith
c852db7708
Merge pull request #180 from github/pr-status-green
...
Print `pr status` numbers in green
2019-12-19 15:31:35 -06:00
Mislav Marohnić
f39d57862d
Clarify -R format
2019-12-19 18:55:31 +01:00
Mislav Marohnić
3346e7b8dc
Print pr status numbers in green
...
We use green to signify "open" state of issues & PRs in `list` commands
(as opposed to red for "closed" and purple for "merged" state), so let's
be consistent in `status` commands too, where all displayed items are
guaranteed to be open.
2019-12-19 17:50:44 +01:00
Mislav Marohnić
9ddd50ffa9
Add tests for pr status reviews and checks output
2019-12-19 17:37:57 +01:00
Mislav Marohnić
fd1da2f0f0
Add test for pr status blank slate
2019-12-19 16:54:24 +01:00
Mislav Marohnić
bd9b3b9bb5
Add tests for issue status/list/create on repos with issues disabled
2019-12-19 15:54:08 +01:00
Mislav Marohnić
aeb7f337d2
Ensure issue create fails fast if issues are disabled
...
Before, a person would be prompted for title & body before
unconditionally failing due to issues being disabled.
2019-12-19 15:44:20 +01:00
Mislav Marohnić
66534e504b
Warn about repo issues disabled on issue create
2019-12-19 15:44:20 +01:00
Mislav Marohnić
915dd8b0ef
Warn about repo issues disabled on issue status/list
2019-12-19 15:44:20 +01:00
Mislav Marohnić
d9ca764ac2
Look up the repository only once in issue status GraphQL
2019-12-19 15:44:20 +01:00
Amanda Pinsker
de814595f5
Clarify repo flag language
2019-12-17 11:22:41 -05:00
Mislav Marohnić
2c1fc56967
Update output expectations
2019-12-17 13:01:45 +01:00
Mislav Marohnić
7b7c985e79
Merge remote-tracking branch 'origin/master' into appropriate-context-and-feedback
2019-12-17 13:00:10 +01:00
Mislav Marohnić
4ad89829c5
Merge remote-tracking branch 'origin/master' into stderr-tests
2019-12-17 12:42:01 +01:00
Corey Johnson
91267a65fa
Fix tests
2019-12-16 13:18:16 -08:00
Corey Johnson
6d0f4e7a90
Add more text
2019-12-16 11:41:56 -08:00
Corey Johnson
2b53172ebe
Add line for pr create
2019-12-16 10:54:22 -08:00
Nate Smith
00da5c2788
Merge pull request #158 from github/issue-create-web
...
Add "Opening URL in your browser" notice to `issue create --web`
2019-12-16 10:53:31 -06:00
Nate Smith
82fbbb28e8
Merge pull request #162 from github/gh-help-lines
...
Avoid long first line of gh help
2019-12-16 10:53:00 -06:00
Mislav Marohnić
030c997301
Avoid long first line of gh help
...
This splits help text over paragraphs and lines to make the output of
`gh` easier to read. It takes care not to go over 80 characters in width
and wraps the URL in `<...>` which will help the URL get auto-linked
when these docs are converted to man and HTML formats.
2019-12-16 15:55:21 +01:00
Mislav Marohnić
48aeff1ca7
Assert stdout separarely from stderr in command tests
...
This stubs stderr separately from stdout in command tests (before those
streams were combined) and improves test assertions around output.
Additionally, no longer use the `cmd.Print*()` family of Cobra functions
because their name sounds like the text will go to stdout, but they
write to stderr instead. Use the more explicit `cmd.ErrOrStderr()` as
output destination instead.
2019-12-16 15:46:42 +01:00
Mislav Marohnić
57c7266328
Fix displaying "There are no issues assigned to you" notice
2019-12-16 14:08:55 +01:00
Mislav Marohnić
5d6b095f1a
Add "Opening URL in your browser" notice to issue create --web
2019-12-16 13:39:22 +01:00
Mislav Marohnić
e93ab66107
Merge pull request #147 from github/pr-to-pull-request
...
Consistently use "pull request" instead of "PR" in user-facing copy
2019-12-13 17:14:17 +01:00
Corey Johnson
0bfd8213e2
Merge pull request #144 from github/better-better-better
...
Better error messages when you don't supply an arg
2019-12-12 11:31:26 -08:00
Corey Johnson
9b5f7a8148
Use new error.As method
2019-12-12 11:09:50 -08:00
Nate Smith
995093591b
s/-B/-T
2019-12-11 15:03:23 -06:00
Corey Johnson
92642f4d53
Create NotFoundError
2019-12-11 10:58:59 -08:00
Corey Johnson
2218e60264
Label as pull request
2019-12-11 10:24:58 -08:00
Corey Johnson
573dda22a1
Simplify flag setting
2019-12-11 10:19:18 -08:00
Mislav Marohnić
cc7b2f0ea8
Consistently use "pull request" instead of "PR" in user-facing copy
2019-12-11 09:31:57 +01:00
Corey Johnson
53ed20f32a
Fix test
2019-12-10 16:15:37 -08:00
Corey Johnson
748b213c9a
Add error details for gh issue view
2019-12-10 16:04:04 -08:00
Corey Johnson
9b40efcad5
Add better gh pr view message
2019-12-10 16:03:10 -08:00
Corey Johnson
5296f72189
Better messaging for gh pr checkout
2019-12-10 16:03:05 -08:00
Corey Johnson
5949ca4b56
Merge pull request #142 from github/empty-pr-list
...
Add empty state for `gh pr list`
2019-12-10 12:04:41 -08:00
Corey Johnson
4de0a76234
Merge pull request #141 from github/add-url-branch-to-usage
...
Add better usage docs for `gh pr view` `gh pr checkout` `gh issue view`
2019-12-06 14:39:43 -08:00
Corey Johnson
eb414bf2a1
Add a little test
2019-12-06 14:33:04 -08:00
Corey Johnson
f70473c234
Replace excessive whitespace
2019-12-06 14:32:55 -08:00