Add com.squareup.okhttp3:mockwebserver as a test dependency to run a "real" HTTP server for the tests
Update tests in AwsRequestSigningApacheV5InterceptorTest to verify request headers/content as seen by the server
Update tests in AwsRequestSigningApacheInterceptorTest to verify request headers/content as seen by the server
Drop MockRequestLine from AwsRequestSigningApacheInterceptorTest since it's no longer needed
Extract the duplicated AddHeaderSigner class from AwsRequestSigningApacheInterceptorTest/AwsRequestSigningApacheV5InterceptorTest so a separate source file
Note: This adds some additional output when running tests. I think this is due to some of the log4j config/deps. I'm happy to add config to suppress it for test execution.
Pull Request Checklist:
[x] I have added a contribution line at the top of CHANGELOG.md.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
I wanted to post this PR before working on any of the other test changes or potentially trying to implement a fix for #101. Let me know if this approach seems okay or not.
Purpose of changes:
Prepare for adding failing tests that cover the issue reported in https://github.com/acm19/aws-request-signing-apache-interceptor/issues/101 (this is impacting us as well). And then subsequently I'd like to follow-up with a patch to fix that issue as well, potentially using the approach mentioned here.
Description of changes:
Note: This adds some additional output when running tests. I think this is due to some of the log4j config/deps. I'm happy to add config to suppress it for test execution.
Pull Request Checklist:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.