V02460
84f441f88f
Prepare unit tests for Python 3.12 ( #16099 )
9 місяці тому
Patrick Cloke
3ac412b4e2
Require types in tests.storage. ( #14646 )
Adds missing type hints to `tests.storage` package
and does not allow untyped definitions.
1 рік тому
Petr Vaněk
bb20113c8f
Remove obsolete RoomEventsStoreTestCase ( #13200 )
All tests are prefixed with `STALE_` and therefore they are silently
skipped. They were moved to `STALE_` in version `v0.5.0` in commit
2fcce3b3c5
- `Remove stale tests`.
Tests from `RoomEventsStoreTestCase` class are not used for last 8
years, I believe the best would be to remove them entirely.
Signed-off-by: Petr Vaněk <arkamar@atlas.cz>
1 рік тому
Erik Johnston
e3163e2e11
Reduce the amount of state we pull from the DB ( #12811 )
2 роки тому
Erik Johnston
1e453053cb
Rename storage classes ( #12913 )
2 роки тому
Patrick Cloke
02d708568b
Replace assertEquals and friends with non-deprecated versions. ( #12092 )
2 роки тому
Richard van der Hoff
e24ff8ebe3
Remove `HomeServer.get_datastore()` ( #12031 )
The presence of this method was confusing, and mostly present for backwards
compatibility. Let's get rid of it.
Part of #11733
2 роки тому
Jonathan de Jong
89cfc3dd98
[pyupgrade] `tests/` ( #10347 )
2 роки тому
Jonathan de Jong
4b965c862d
Remove redundant "coding: utf-8" lines ( #9786 )
Part of #9744
Removes all redundant `# -*- coding: utf-8 -*-` lines from files, as python 3 automatically reads source code as utf-8 now.
`Signed-off-by: Jonathan de Jong <jonathan@automatia.nl>`
3 роки тому
Patrick Cloke
e7b769aea1
Convert storage test cases to HomeserverTestCase. ( #9736 )
3 роки тому
Patrick Cloke
4c6c56dc58
Convert simple_select_one and simple_select_one_onecol to async ( #8162 )
3 роки тому
Patrick Cloke
b3a97d6dac
Convert some of the data store to async. ( #7976 )
3 роки тому
Patrick Cloke
3345c166a4
Convert storage layer to async/await. ( #7963 )
3 роки тому
Patrick Cloke
b975fa2e99
Convert state resolution to async/await ( #7942 )
3 роки тому
Dirk Klimpel
491f0dab1b
Add delete room admin endpoint ( #7613 )
The Delete Room admin API allows server admins to remove rooms from server
and block these rooms.
`DELETE /_synapse/admin/v1/rooms/<room_id>`
It is a combination and improvement of "[Shutdown room](https://github.com/matrix-org/synapse/blob/develop/docs/admin_api/shutdown_room.md )" and "[Purge room](https://github.com/matrix-org/synapse/blob/develop/docs/admin_api/purge_room.md )" API.
Fixes : #6425
It also fixes a bug in [synapse/storage/data_stores/main/room.py](synapse/storage/data_stores/main/room.py) in ` get_room_with_stats`.
It should return `None` if the room is unknown. But it returns an `IndexError`.
901b1fa561/synapse/storage/data_stores/main/room.py (L99-L105)
Related to:
- #5575
- https://github.com/Awesome-Technologies/synapse-admin/issues/17
Signed-off-by: Dirk Klimpel dirk@klimpel.org
3 роки тому
Manuel Stahl
a4a5ec4096
Add room details admin endpoint ( #7317 )
4 роки тому
Erik Johnston
8df862e45d
Add `rooms.room_version` column ( #6729 )
This is so that we don't have to rely on pulling it out from `current_state_events` table.
4 роки тому
Erik Johnston
3ca4c7c516
Use new EventPersistenceStore
4 роки тому
Amber Brown
32e7c9e7f2
Run Black. ( #5482 )
5 роки тому
Amber Brown
99dd975dae
Run tests under PostgreSQL ( #3423 )
5 роки тому
black
8b3d9b6b19
Run black.
5 роки тому
Amber Brown
49af402019
run isort
6 роки тому
Mark Haines
700487a7c7
Fix flake8 warnings for tests
8 роки тому
Erik Johnston
f8aae79a72
Simplify get_rooms
8 роки тому
Matthew Hodgson
6c28ac260c
copyrights
8 роки тому
Daniel Wagner-Hall
cf437900e0
Return world_readable and guest_can_join in /publicRooms
8 роки тому
Daniel Wagner-Hall
7213588083
Implement configurable stats reporting
SYN-287
This requires that HS owners either opt in or out of stats reporting.
When --generate-config is passed, --report-stats must be specified
If an already-generated config is used, and doesn't have the
report_stats key, it is requested to be set.
8 роки тому
Erik Johnston
7e282a53a5
Tidy up _simple_... methods
9 роки тому
Mark Haines
896253e085
Factor out some of the common homeserver setup code into a
setup_test_homeserver function in utils.
9 роки тому
Mark Haines
ada711504e
Replace hs.parse_roomalias with RoomAlias.from_string
9 роки тому
Mark Haines
1c06c48ce2
Replace hs.parse_roomid with RoomID.from_string
9 роки тому
Mark Haines
5759bec43c
Replace hs.parse_userid with UserID.from_string
9 роки тому
Mark Haines
3891597eb3
Remove unused functions
9 роки тому
Erik Johnston
3c77d13aa5
Kill off synapse.api.events.*
9 роки тому
Erik Johnston
2fcce3b3c5
Remove stale tests
9 роки тому
Paul "LeoNerd" Evans
bcf5121937
Neaten more of the storage layer tests with assertObjectHasAttributes; more standardisation on test layout
9 роки тому
Paul "LeoNerd" Evans
b588ce920d
Unit tests for (some) room events via the RoomStore
9 роки тому
Paul "LeoNerd" Evans
ba41ca45fa
Use new assertObjectHasAttributes() in tests/storage/test_room.py
9 роки тому
Paul "LeoNerd" Evans
de14853237
More RoomStore tests
9 роки тому
Paul "LeoNerd" Evans
e32cfed1d8
Initial pass at a RoomStore test
9 роки тому
Paul "LeoNerd" Evans
ae7dfeb5b6
Use new 'tests.unittest' in new storage level tests
9 роки тому
Paul "LeoNerd" Evans
493b1e6d3c
Need to prepare() the SQLiteMemoryDbPool before passing it to HomeServer constructor, as DataStore's constructor will want it ready
9 роки тому
Paul "LeoNerd" Evans
dd1a9100c5
Added unit tests for PresenceDataStore too
9 роки тому
Paul "LeoNerd" Evans
dc7f39677f
Remember to kill now-dead import in test_profile.py
9 роки тому
Paul "LeoNerd" Evans
08f5c48fc8
Move SQLiteMemoryDbPool implementation into tests.utils
9 роки тому
Paul "LeoNerd" Evans
9774949cc9
It's considered polite to actually wait for DB prepare before running tests
9 роки тому
Paul "LeoNerd" Evans
53d0f69dc3
Also test avatar_url profile field
9 роки тому
Paul "LeoNerd" Evans
6081f4947e
Tiny trivial PoC unit-test using SQLite in :memory: mode
9 роки тому