synapse-product/tests
Tim Leung ddb240293a
Add support for no_proxy and case insensitive env variables (#9372)
### Changes proposed in this PR

- Add support for the `no_proxy` and `NO_PROXY` environment variables
  - Internally rely on urllib's [`proxy_bypass_environment`](bdb941be42/Lib/urllib/request.py (L2519))
- Extract env variables using urllib's `getproxies`/[`getproxies_environment`](bdb941be42/Lib/urllib/request.py (L2488)) which supports lowercase + uppercase, preferring lowercase, except for `HTTP_PROXY` in a CGI environment

This does contain behaviour changes for consumers so making sure these are called out:
- `no_proxy`/`NO_PROXY` is now respected
- lowercase `https_proxy` is now allowed and taken over `HTTPS_PROXY`

Related to #9306 which also uses `ProxyAgent`

Signed-off-by: Timothy Leung tim95@hotmail.co.uk
2021-02-26 17:37:57 +00:00
..
api Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
app Remove spurious "SynapseRequest" result from `make_request" 2020-12-15 22:35:40 +00:00
appservice Add ability for access tokens to belong to one user but grant access to another user. (#8616) 2020-10-29 15:58:44 +00:00
config Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
crypto Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
events Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
federation Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
handlers Fix style checking due to updated black. 2021-02-19 08:19:54 -05:00
http Add support for no_proxy and case insensitive env variables (#9372) 2021-02-26 17:37:57 +00:00
logging Various clean-ups to the logging context code (#8935) 2020-12-14 14:19:47 -05:00
module_api Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
push Test that we require validated email for email pushers (#9496) 2021-02-25 15:35:14 +00:00
replication Clean up ShardedWorkerHandlingConfig (#9466) 2021-02-24 13:23:18 +00:00
rest SSO: redirect to public URL before setting cookies (#9436) 2021-02-26 14:02:06 +00:00
scripts Port register_new_matrix_user to Python 3 and add tests (#4085) 2018-10-26 22:05:22 +11:00
server_notices Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
state Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
storage Add the shadow-banning status to the display user admin API. (#9400) 2021-02-17 15:19:23 -05:00
test_utils Fix bugs in handling clientRedirectUrl, and improve OIDC tests (#9127, #9128) 2021-01-18 14:52:49 +00:00
util Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
__init__.py Move patch_inline_callbacks into synapse/ 2019-10-10 10:53:06 +01:00
server.py SSO: redirect to public URL before setting cookies (#9436) 2021-02-26 14:02:06 +00:00
test_distributor.py Run black. 2018-08-10 23:54:09 +10:00
test_event_auth.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
test_federation.py Various clean-ups to the logging context code (#8935) 2020-12-14 14:19:47 -05:00
test_mau.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
test_metrics.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
test_phone_home.py Allow background tasks to be run on a separate worker. (#8369) 2020-10-02 08:23:15 -04:00
test_preview.py Handle additional errors when previewing URLs. (#9333) 2021-02-08 12:33:30 -05:00
test_server.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
test_state.py Add admin API for logging in as a user (#8617) 2020-11-17 10:51:25 +00:00
test_terms_auth.py Remove spurious "SynapseRequest" result from `make_request" 2020-12-15 22:35:40 +00:00
test_test_utils.py Run black. 2018-08-10 23:54:09 +10:00
test_types.py Add basic domain validation for DomainSpecificString.is_valid. (#9071) 2021-01-13 07:05:16 -05:00
test_visibility.py Stop sub-classing object (#8249) 2020-09-04 06:54:56 -04:00
unittest.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
utils.py Remove vestiges of uploads_path config (#9462) 2021-02-22 19:54:49 +00:00