waterbutler
waterbutler copied to clipboard
[SVCS-475] Send hook request to OSF for GET requests
Ticket
https://openscience.atlassian.net/browse/SVCS-475
Purpose
This PR replaces: https://github.com/CenterForOpenScience/waterbutler/pull/277.
The goal of this PR is to send a hook request for all file requests, including GETs so that the osf-side can better track provider metadata. I've also added some unit tests to improve coverage going forward.
Changes
Modifies the accepted actions for sending hooks and creates groups of parameterized tests so the desired action behavior is more obvious.
Side effects
In order to compare LogPayload instances which aren't returned by the logging function, I've have to modify the eq method of the the LogPayload to compare by serialization instead of the typical instance to instance comparison.
QA Notes
None. This is not a user facing change.
Deployment Notes
Requires osf-side changes to have any utility.
Coverage increased (+0.4%) to 90.22% when pulling 307b9e856e17aa289801146e3f964de2ffc7ded8 on Johnetordoff:feature/metadata-logging into 3ec764ae879c107c405d67b1e2d60d1018eafa96 on CenterForOpenScience:develop.
Coverage increased (+0.4%) to 90.22% when pulling f722ad4dbdd78f36a5c2f807a9710189d939c9aa on Johnetordoff:feature/metadata-logging into 3ec764ae879c107c405d67b1e2d60d1018eafa96 on CenterForOpenScience:develop.
Coverage increased (+0.4%) to 90.316% when pulling 6ff7a99141a1461eb39bbde667813e3e08c52615 on Johnetordoff:feature/metadata-logging into cae41fcbde459a4a153bd492de3ddbea90241139 on CenterForOpenScience:develop.
~~Update: secondary PR pending.~~ LGTM, move to PCR. 🎆 🎆