feat: Azure more new new resource manager SDK#5286
Closed
yevgenypats wants to merge 5 commits intomainfrom
Closed
Conversation
candiduslynx
reviewed
Dec 2, 2022
Contributor
candiduslynx
left a comment
There was a problem hiding this comment.
Not sure about http mocks at all
| if err != nil { | ||
| return services, err | ||
| } | ||
| services.ArmkeyvaultVaults = ArmkeyvaultVaults |
Contributor
There was a problem hiding this comment.
a good idea to init in-place.
I'd go even further and do it like this:
var err error
var services Services
services.ClientA, err = initClientA(...)
if err != nil {
return services, err
}
...Maybe I'll add it to my PR codegen as well
| return nil, err | ||
| } | ||
| emptyStr := "" | ||
| item.NextLink = &emptyStr |
Contributor
There was a problem hiding this comment.
Suggested change
| item.NextLink = &emptyStr | |
| item.NextLink = nil |
OR
Suggested change
| item.NextLink = &emptyStr | |
| item.NextLink = to.Ptr("") |
| emptyStr := "" | ||
| item.NextLink = &emptyStr | ||
| mux := httprouter.New() | ||
| mux.GET("/*filepath", func(w http.ResponseWriter, r *http.Request, _ httprouter.Params) { |
Contributor
There was a problem hiding this comment.
I personally don't see a lot of difference between the generated interface + mock on it vs transport-based mock tests, but prefer the interface+mocks better.
|
|
||
|
|
||
| type Client struct { | ||
| subscriptions []string |
Contributor
There was a problem hiding this comment.
this info is already present in services as keys
yevgenypats
added a commit
that referenced
this pull request
Dec 11, 2022
This PR comes instead of this #5286 as old pr got messed up. This generates the autogeneration code and tries to generate the whole huge Azure SDK completely. Co-authored-by: Erez Rokah <erezrokah@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a draft PR that helps me review #4768. I'll either apply fixes on top #4768 or will use this one directly if it will be much better.