Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion trafficlight/internals/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ async def enable_key_backup(self, key_backup_passphrase: str) -> None:
)

async def open_room(self, room_name: str) -> None:
await self._perform_action({"action": "open-room", "data": {"name": room_name}})
await self._perform_action({"action": "open_room", "data": {"name": room_name}})

async def advance_clock(self, duration: int) -> None:
await self._perform_action(
Expand Down
7 changes: 4 additions & 3 deletions trafficlight/tests/retry_sendToDevice_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
from trafficlight.server_types import SynapseDevelop


# CLIENT_COUNT=2 REQUIRES_PROXY=true CYPRESS_BASE_URL="https://app.element.io" ./trafficlight/scripts-dev/run-localdev-setup.sh && tmux kill-server
# TEST STATUS: PASSING
class RetrySendToDeviceTest(Test):
def __init__(self) -> None:
super().__init__()
Expand All @@ -23,10 +25,9 @@ async def run(
network_proxy: NetworkProxyClient,
) -> None:
await network_proxy.proxy_to(server)
await alice.register(network_proxy)
await asyncio.gather(alice.register(network_proxy), bob.register(server))

await alice.create_room("little test room")
await bob.register(server)
await alice.invite_user(bob.localpart + ":" + server.server_name)
await bob.accept_invite()
await network_proxy.disable_endpoint("/_matrix/client/r0/sendToDevice")
Expand All @@ -39,5 +40,5 @@ async def run(
await network_proxy.wait_until_endpoint_accessed(
"/_matrix/client/r0/sendToDevice"
)
await asyncio.sleep(5000)
await asyncio.sleep(5)
await bob.verify_message_in_timeline("A random message appears!")
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@
from trafficlight.server_types import SynapseDevelop

# Test Script:
# CLIENT_COUNT=2 REQUIRES_PROXY=true CYPRESS_BASE_URL="https://develop.element.io"
# ./trafficlight/scripts-dev/run-localdev-setup.sh && tmux kill-server
# CLIENT_COUNT=2 REQUIRES_PROXY=true CYPRESS_BASE_URL="https://develop.element.io" ./trafficlight/scripts-dev/run-localdev-setup.sh && tmux kill-server

# Test Status: Passing


class VerifyWhenToDeviceMessagesOutOfOrder(Test):
Expand Down