[Bugfix] Bearer Token Authentication was generating wrong header value #52
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.
Hello,
I was trying today to update my gem asana_exception_notifier which has a dependency to this gem when i discovered that i was getting a warning :
After debugging the calls i was making to Asana API, i discovered that this gem was not configured properly for bearer token authentication, and because of that Faraday was generating a wrong header
instead of
This pull requests configures correctly the Faraday configuration in the class Asana::Authentication::OAuth2::BearerTokenAuthentication
Also added tests for checking that the header generated by Faraday is correct, and integrated Appraisal gem also so that we can test backward compatibility.
Alll tests are passing locally .
Please let me know what you think. If you want i can keep the old way the gem was working and make another class for this and setup a new authorization type in the Configuration class if needed.
Thank you very much.
┆Issue is synchronized with this Asana task