Run tests under PostgreSQL (#3423)

This commit is contained in:
Amber Brown 2018-08-13 16:47:46 +10:00 committed by GitHub
parent a001038b92
commit 99dd975dae
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
49 changed files with 227 additions and 59 deletions

View file

@ -96,6 +96,11 @@ class ClientIpStore(background_updates.BackgroundUpdateStore):
self._batch_row_update[key] = (user_agent, device_id, now)
def _update_client_ips_batch(self):
# If the DB pool has already terminated, don't try updating
if not self.hs.get_db_pool().running:
return
def update():
to_update = self._batch_row_update
self._batch_row_update = {}