-
Notifications
You must be signed in to change notification settings - Fork 372
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ISSUE-696: Explore use of t.TempDir() #702
Conversation
Welcome @Evalle! |
Ideally we'd get rid of this type. |
@ahmetb thanks for the feedback! Just to be clear, you would like to get rid of NewTempDir completely or of type Tempdir I'm pretty new in golang so my question could sound strange. Thanks! |
@Evalle Can you have a look how the methods on the If there are a lot of usages, your current PR looks good to me. |
@corneliusweig thanks for the comment. My first intention was to get rid of
And the above functionality used by many tests, for example: |
Yeah I was expecting maybe we have simpler unit test usages that just do NewTestUtil() in a single test function. For those, t.TempDir() can be better. But right now, there's no reason to split the usage into two. We can just accept this. Any developer/build system will need to update to |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ahmetb, Evalle The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Thanks @ahmetb and @corneliusweig for the reviews |
PR Summary:
For the reviewers:
I'm not sure this is the right implementation, as @ahmetb asked to deprecate the implementation of
testutil.NewTempDir(t)
should I add somedeprecation notice
? Thanks in advance for the advices/reviews.