Skip to content
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

put accept header before OnRequest #786

Merged
merged 4 commits into from
Oct 20, 2023
Merged

put accept header before OnRequest #786

merged 4 commits into from
Oct 20, 2023

Conversation

k4lizen
Copy link
Contributor

@k4lizen k4lizen commented Oct 3, 2023

Closes #783 .

Copy link
Collaborator

@WGH- WGH- left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mind writing a unit test for this?

@k4lizen
Copy link
Contributor Author

k4lizen commented Oct 17, 2023

Is that satisfactory? I'm not quite sure what else I could test

@WGH-
Copy link
Collaborator

WGH- commented Oct 17, 2023

Is that satisfactory? I'm not quite sure what else I could test

Well, the test should ensure that no Accept header actually hits the server

@k4lizen
Copy link
Contributor Author

k4lizen commented Oct 17, 2023

Like this?

@WGH-
Copy link
Collaborator

WGH- commented Oct 17, 2023

Right now you only verify what you think you send, not what the server sees. Check the existing TestHeaders test, it's a good example.

@k4lizen
Copy link
Contributor Author

k4lizen commented Oct 18, 2023

Now? :)

Copy link
Collaborator

@WGH- WGH- left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks!

@WGH- WGH- merged commit 3c987f1 into gocolly:master Oct 20, 2023
7 checks passed
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.

Cannot send request with no Accept header
3 participants