mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 10:46:06 -04:00
Use a sender localpart instead of a user ID.
Form the user ID at runtime instead, This gives less room for error in AS config files since they cannot specify the domain of another HS.
This commit is contained in:
parent
3470cb36a8
commit
cf1fa59f4b
2 changed files with 11 additions and 4 deletions
|
@ -60,7 +60,7 @@ class ApplicationServiceStoreTestCase(unittest.TestCase):
|
|||
|
||||
def _add_appservice(self, as_token, url, hs_token, sender):
|
||||
as_yaml = dict(url=url, as_token=as_token, hs_token=hs_token,
|
||||
sender=sender, namespaces={})
|
||||
sender_localpart=sender, namespaces={})
|
||||
# use the token as the filename
|
||||
with open(as_token, 'w') as outfile:
|
||||
outfile.write(yaml.dump(as_yaml))
|
||||
|
@ -138,7 +138,7 @@ class ApplicationServiceTransactionStoreTestCase(unittest.TestCase):
|
|||
|
||||
def _add_service(self, url, as_token):
|
||||
as_yaml = dict(url=url, as_token=as_token, hs_token="something",
|
||||
sender="a_sender", namespaces={})
|
||||
sender_localpart="a_sender", namespaces={})
|
||||
# use the token as the filename
|
||||
with open(as_token, 'w') as outfile:
|
||||
outfile.write(yaml.dump(as_yaml))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue