0
0
Fork 1
mirror of https://mau.dev/maunium/synapse.git synced 2024-12-16 23:03:53 +01:00
synapse/tests/config
David Robertson e2a1adbf5d
Allow selecting "prejoin" events by state keys (#14642)
* Declare new config

* Parse new config

* Read new config

* Don't use trial/our TestCase where it's not needed

Before:

```
$ time trial tests/events/test_utils.py > /dev/null

real	0m2.277s
user	0m2.186s
sys	0m0.083s
```

After:
```
$ time trial tests/events/test_utils.py > /dev/null

real	0m0.566s
user	0m0.508s
sys	0m0.056s
```

* Helper to upsert to event fields

without exceeding size limits.

* Use helper when adding invite/knock state

Now that we allow admins to include events in prejoin room state with
arbitrary state keys, be a good Matrix citizen and ensure they don't
accidentally create an oversized event.

* Changelog

* Move StateFilter tests

should have done this in #14668

* Add extra methods to StateFilter

* Use StateFilter

* Ensure test file enforces typed defs; alphabetise

* Workaround surprising get_current_state_ids

* Whoops, fix mypy
2022-12-13 00:54:46 +00:00
..
__init__.py Remove redundant "coding: utf-8" lines (#9786) 2021-04-14 15:34:27 +01:00
test___main__.py Fix synapse.config module "read" command (#11145) 2021-10-22 12:00:52 +02:00
test_api.py Allow selecting "prejoin" events by state keys (#14642) 2022-12-13 00:54:46 +00:00
test_background_update.py Add config settings for background update parameters (#11980) 2022-03-11 10:46:45 -08:00
test_base.py Require direct references to configuration variables. (#10985) 2021-10-06 10:47:41 -04:00
test_cache.py Reload cache factors from disk on SIGHUP (#12673) 2022-05-11 13:43:22 +00:00
test_database.py Remove redundant "coding: utf-8" lines (#9786) 2021-04-14 15:34:27 +01:00
test_generate.py Remove redundant "coding: utf-8" lines (#9786) 2021-04-14 15:34:27 +01:00
test_load.py Add missing type hints to config base classes (#11377) 2021-11-23 15:21:19 +00:00
test_ratelimiting.py Use direct references for configuration variables (part 4). (#10893) 2021-09-23 12:03:01 -04:00
test_registration_config.py Add missing type hints to config classes. (#12402) 2022-04-11 12:07:23 -04:00
test_room_directory.py Remove redundant "coding: utf-8" lines (#9786) 2021-04-14 15:34:27 +01:00
test_server.py Add missing type hints to config classes. (#12402) 2022-04-11 12:07:23 -04:00
test_tls.py Require direct references to configuration variables. (#10985) 2021-10-06 10:47:41 -04:00
test_util.py Remove redundant "coding: utf-8" lines (#9786) 2021-04-14 15:34:27 +01:00
test_workers.py Add the update_user_directory_from_worker configuration option (superseding update_user_directory) to allow a generic worker to be designated as the worker to update the user directory. (#12654) 2022-05-10 11:08:45 +01:00
utils.py Fix synapse.config module "read" command (#11145) 2021-10-22 12:00:52 +02:00