You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
)
What I think is, instead of stubbing and putting demo files in the flow, we can actually utilize the existing template files in the flow.
Let gh select our existing issue and pr templates from the file system, and then when the user selects that particular option of the template, we can directly check if the contents are proper.
(And we don't need to check for the change due to the user opening the text editor, as that is the job of the surveyext library, and we can assume that it is well tested.)
Also, we already have github_template_test.go for template content extraction stuff testing.
In case I was unable to put forth my ideas clearly, I believe that I will be able to show it better via a PR. (and commenting on my changes there)
oop, page was out of date. I'm happy to look at a PR and discuss there. Thanks for thinking about it and for checking in! Assign me as a reviewer, please.
Activity
AliabbasMerchant commentedon May 18, 2020
Also, we need tests for interactive mode in issue/pr creation
AliabbasMerchant commentedon May 18, 2020
Can I take up the tests for the interactive mode?
I tried it out locally, and the tests I wrote are working.
I can later on try stubbing the template file selection also
AliabbasMerchant commentedon May 18, 2020
Got the solution!
I feel we actually don't need to exactly stub the template file selection.
(Your comments here:
cli/command/issue.go
Line 362 in 4d11732
cli/command/pr_create.go
Line 218 in 4d11732
What I think is, instead of stubbing and putting demo files in the flow, we can actually utilize the existing template files in the flow.
Let
ghselect our existing issue and pr templates from the file system, and then when the user selects that particular option of the template, we can directly check if the contents are proper.(And we don't need to check for the change due to the user opening the text editor, as that is the job of the
surveyextlibrary, and we can assume that it is well tested.)Also, we already have
github_template_test.gofor template content extraction stuff testing.In case I was unable to put forth my ideas clearly, I believe that I will be able to show it better via a PR. (and commenting on my changes there)
vilmibm commentedon May 18, 2020
sure, if you are up to it! Let me know if you have any questions or difficulties with the
AskStubberandCommandStubberhelpers.vilmibm commentedon May 18, 2020
oop, page was out of date. I'm happy to look at a PR and discuss there. Thanks for thinking about it and for checking in! Assign me as a reviewer, please.