Skip to content

preserve RequestURI#5

Merged
markbates merged 2 commits intogobuffalo:masterfrom
gochigo:preserve-request-uri
Nov 21, 2018
Merged

preserve RequestURI#5
markbates merged 2 commits intogobuffalo:masterfrom
gochigo:preserve-request-uri

Conversation

@sio4
Copy link
Copy Markdown
Member

@sio4 sio4 commented Nov 19, 2018

When httptest.Request creates http.Request by calling http.NewRequest directly, it does not preserve second parameter url as Request.RequestURI, the unmodified request-target. As a result, if a user's application uses something like context.Request().RequestURI, the app works fine with RequestURI but testing with httptest will failed since there is no RequestURI on the structure.

This PR just added the value manually to present RequestURI as the user expected.

@sio4
Copy link
Copy Markdown
Member Author

sio4 commented Nov 21, 2018

It fails on windows tests since "make not found".

@markbates
Copy link
Copy Markdown
Member

markbates commented Nov 21, 2018 via email

@sio4
Copy link
Copy Markdown
Member Author

sio4 commented Nov 21, 2018

Yes, I found the update and pushed merged version already. (since I faced it does not run checks when I just rebased, so I just merge with master.)

@markbates markbates merged commit dd4e2be into gobuffalo:master Nov 21, 2018
@sio4 sio4 deleted the preserve-request-uri branch November 21, 2018 04:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants