diff --git a/tests/41end-to-end-keys/06-device-lists.pl b/tests/41end-to-end-keys/06-device-lists.pl index 4ed3b77e0..73b963155 100644 --- a/tests/41end-to-end-keys/06-device-lists.pl +++ b/tests/41end-to-end-keys/06-device-lists.pl @@ -788,3 +788,19 @@ sub sync_until_user_in_device_list Future->done(1); }); }; + +# regression test for https://github.com/matrix-org/synapse/pull/7160 +test "Users receive device_list updates for their own devices", + requires => [ local_user_fixture(), qw( can_sync ) ], + + check => sub { + my ( $user1 ) = @_; + + matrix_sync( $user1 )->then( sub { + matrix_login_again_with_user( $user1 ); + })->then( sub { + sync_until_user_in_device_list( $user1, $user1 ); + })->then( sub { + die; + }); + };