- First commit to issue fork.
- Merge request !214Issue #3071168: Add custom http headers to requests → (Open) created by codebymikey
Provided a new configuration option for specifying HTTP headers that may be specified on the Feed type or individual Feed entity level.
- 🇮🇹Italy kopeboy Milan
Even if I don't have a real URL to test now, this seems working. Thanks!
- 🇳🇱Netherlands megachriz
Nice work so far! I've some remarks:
- I think that we should avoid
<code>tags in translatable strings. - On the feed form, it would be useful to see what the default configured headers are, maybe as a placeholder for the textarea.
- I think it would be better if the configured http headers are saved as an array instead of a string. For both the feed type and the feed.
- Needs tests.
Test coverage
-
Functional test for configuring a feed type with http headers:
- Assert that misconfigured headers result into a validation error.
- Assert that empty lines are ignored and not saved as configuration.
- Assert that configured headers are saved.
- Functional test for configuring a feed with http headers override: test the same things as for configuring a feed type with http headers.
- Unit test for asserting the expected headers when they are configured on the feed type.
- Unit test for asserting the expected headers when they are configured on the feed.
- Unit test for asserting the expected headers when they are configured on both the feed type and the feed.
- I think that we should avoid