Cristian Dominguez
2f94adabb2
Use T.TempDir for temporary dirs in tests ( #3580 )
2021-05-07 12:21:26 +02:00
Mislav Marohnić
a2ff97d73f
Fix issue create --web
2021-04-20 13:50:44 +02:00
Mislav Marohnić
57536e7b0d
💅 cleanup URL length checking
2021-03-30 19:12:31 +02:00
Cristian Dominguez
fb39c38c85
Disable preview option in prompts if URL size is too long
2021-03-30 19:12:31 +02:00
Mislav Marohnić
111e8dbcf2
Pass web browser to each individual command
...
This removes sensitivity to the BROWSER environment variable in tests
and makes it easier to verify the URL that the browser was invoked with
without having to stub sub-processes.
2021-03-19 21:22:37 +01:00
Mislav Marohnić
e96d974331
Merge pull request #3023 from cli/cancel-error-status
...
Issue/pr create: exit with nonzero status code when "Cancel" was chosen
2021-03-04 13:45:11 +01:00
Mislav Marohnić
2ebdde1ddd
Exit with status code "2" on user cancellation errors
...
This also stops printing "interrupt" after Ctrl-C is pressed.
2021-03-02 13:48:44 +01:00
Mislav Marohnić
3efa764305
Avoid the issue/pr recovery mechanism handling Ctrl-C keypress in prompts
...
Either InterruptErr or SilentErr will be present when the user has
chosen "Cancel" or pressed Ctrl-C in prompts. We don't want the recovery
mechanism to kick in these cases because the cancellation was likely
willingly initiated by the user.
2021-02-23 20:09:03 +01:00
Mislav Marohnić
fff051468e
Avoid triggering recovery mechanism when cancelling issue/pr create
2021-02-23 19:42:41 +01:00
Mislav Marohnić
b0b90afa87
issue/pr create: exit with nonzero status code when "Cancel" was chosen
...
This is to indicate that the command had not finished successfully.
2021-02-23 17:06:29 +01:00
Mislav Marohnić
fee7adf9ba
Add issue create -F <file> flag and tests
2021-02-23 14:25:32 +01:00
Mislav Marohnić
0cd5744398
Un-export HasAPI leaky abstraction
2021-02-17 17:08:50 +01:00
Mislav Marohnić
3ddd93793c
Port issue create to using templates API
2021-02-10 17:32:00 +01:00
Devon Romanko
9dcd3fbacf
use Stub instead of SetPrepareCmd in 'issue create' tests
2021-01-26 08:24:22 -05:00
AliabbasMerchant
1c54db4919
fix: Project Argument working along with --web flag
2021-01-22 23:07:00 +01:00
Mislav Marohnić
e334a1f10c
Add docs for using @me to reference self
2021-01-22 22:14:47 +01:00
Mislav Marohnić
28c2d042e7
Extend @me replacing behavior to issue list
2021-01-22 22:05:33 +01:00
Marc Lopez
6ad0c57a31
issue/pr create: add "@me" syntax to self-assign
...
Signed-off-by: Marc Lopez <marc5.12@outlook.com>
2021-01-22 20:41:17 +01:00
Mislav Marohnić
06cf2c9f81
Merge remote-tracking branch 'origin' into cmd-stub-new
2021-01-22 16:31:29 +01:00
Mislav Marohnić
75ebb863e3
Use testify assertions for error matching
2021-01-19 13:59:37 +01:00
Cristian Dominguez
45f4a1f087
Equal: flip arguments position
2021-01-18 21:00:59 -03:00
Mislav Marohnić
c308f1cd91
Prevent further use of SetPrepareCmd and InitCmdStubber
2021-01-18 22:44:53 +01:00
Cristian Dominguez
3afb1d0b1a
Use Testify assertions in test
2021-01-16 19:19:30 -03:00
Cristian Dominguez
ce151420f3
Migrate legacy tests
2021-01-11 21:07:19 -03:00
Mislav Marohnić
f4152454f2
Merge pull request #2472 from cristiand391/preserve-metadata-state
...
Prompt: avoid resetting PR/issue metadata
2020-12-03 18:51:29 +01:00
Mislav Marohnić
be39f4363b
Make MetadataSurvey testable by accepting an interface
2020-12-03 17:47:40 +01:00
Mislav Marohnić
df2ca9c9f9
Fix browser URL test on Windows
2020-12-01 15:55:40 +01:00
Mislav Marohnić
dc1fad9cb0
Fix respecting chosen action in interactive issue create
...
The `action` variable started being shadowed in the `if` block in
6671106448
2020-12-01 15:28:39 +01:00
vilmibm
cf37ce7463
no shorthand for --recover
2020-11-23 11:24:28 -08:00
vilmibm
d6e84a75fb
switch to recover instead of resubmit
2020-11-23 11:21:34 -08:00
vilmibm
d300526318
preserve and restore issue/pr input on failure
2020-11-23 11:21:28 -08:00
Josh Soref
ded92972cd
spelling: template
2020-11-21 21:43:51 -05:00
vilmibm
ef52376fe0
fix survey invocation
2020-11-13 10:35:32 -08:00
vilmibm
f5277e452e
get everything working
2020-11-12 12:03:32 -08:00
vilmibm
6671106448
WIP works, probably some title/body input edge cases
2020-11-12 12:03:20 -08:00
Mislav Marohnić
f9239661f2
Reuse the StubRepoInfoReponse test helper
2020-09-16 15:01:13 +02:00
vilmibm
1073c97409
review feedback
2020-09-11 11:36:24 -05:00
vilmibm
c0fc31f7d5
use CanPrompt in commands
2020-09-10 12:13:48 -05:00
AliabbasMerchant
51c5595cad
Interactive template selection test for PR create
2020-09-02 09:56:28 +05:30
AliabbasMerchant
d0c2c81f2d
Interactive template selection test for issue create
2020-08-27 13:39:21 +05:30
Mislav Marohnić
c00fe73d5a
Isolate issue commands
2020-08-07 00:27:55 +02:00