public void RpcOnPlayerAdded(Player[] allPlayers)
 {
     if (_networkBehaviourChecker.IsLocalPlayer(this))
     {
         _uiController.UpdateLobby(allPlayers);
     }
 }
        public void RpcOnPlayerAdded_ShouldUpdateLobbyView_WhenPlayerHasAuthority()
        {
            // Given
            var players = new[]
            {
                new Player("Player Name 1"),
                new Player("Player Name 2"),
            };

            _networkBehaviourChecker
            .IsLocalPlayer(_playerController)
            .Returns(true);

            // When
            _playerController.RpcOnPlayerAdded(players);

            // Then
            _uiController
            .Received()
            .UpdateLobby(players);
        }