Skip to content

Commit

Permalink
fix upstream req method
Browse files Browse the repository at this point in the history
  • Loading branch information
rucciva committed Jun 18, 2024
1 parent 6d8dcfe commit d29142a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/proxy/generate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ func TestGenerate(t *testing.T) {
cmd.Dir = "testoutput"
out, err := cmd.Output()
t.Log("\n" + string(out))
require.NoError(t, err)
assert.Equal(t, 0, cmd.ProcessState.ExitCode())
require.NoError(t, err, "test for generated code should not return error")
assert.Equal(t, 0, cmd.ProcessState.ExitCode(), "test for generated code should not exit with non-zero status code")
}
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@
{{end}}{{/* if .QueryParams */}}

req := base.Clone(base.Context())
req.Method = "{{.Method}}"
req.URL = queryURL

{{ if .HeaderParams }}
Expand Down
2 changes: 2 additions & 0 deletions internal/proxy/testoutput/oapi-proxy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit d29142a

Please sign in to comment.