From a649acd7d5b406a96b33057767c335973866e344 Mon Sep 17 00:00:00 2001 From: Askaholic Date: Tue, 17 Oct 2023 17:17:11 -0400 Subject: [PATCH] Remove deprecated player_info fields --- server/players.py | 4 ---- tests/integration_tests/test_login.py | 12 ------------ tests/integration_tests/test_teammatchmaker.py | 6 ------ tests/unit_tests/test_players.py | 3 --- 4 files changed, 25 deletions(-) diff --git a/server/players.py b/server/players.py index 13529005e..b4467e9fb 100644 --- a/server/players.py +++ b/server/players.py @@ -154,10 +154,6 @@ def filter_none(t): } for rating_type in self.ratings }), - # Deprecated - ("global_rating", self.ratings[RatingType.GLOBAL]), - ("ladder_rating", self.ratings[RatingType.LADDER_1V1]), - ("number_of_games", self.game_count[RatingType.GLOBAL]), ) ) ) diff --git a/tests/integration_tests/test_login.py b/tests/integration_tests/test_login.py index cb67fe62f..b10128cab 100644 --- a/tests/integration_tests/test_login.py +++ b/tests/integration_tests/test_login.py @@ -72,9 +72,6 @@ async def test_server_valid_login(lobby_server): "number_of_games": 2 } }, - "global_rating": [1650.0, 62.52], - "ladder_rating": [1650.0, 62.52], - "number_of_games": 2 } assert msg == { "command": "welcome", @@ -115,9 +112,6 @@ async def test_server_valid_login_admin(lobby_server): "number_of_games": 5 } }, - "global_rating": [2000.0, 125.0], - "ladder_rating": [2000.0, 125.0], - "number_of_games": 5, } assert msg == { "command": "welcome", @@ -157,9 +151,6 @@ async def test_server_valid_login_moderator(lobby_server): "number_of_games": 0 } }, - "global_rating": [1500, 500], - "ladder_rating": [1500, 500], - "number_of_games": 0 } assert msg == { "command": "welcome", @@ -251,9 +242,6 @@ async def test_server_valid_login_with_token(lobby_server, jwk_priv_key, jwk_kid "number_of_games": 2 } }, - "global_rating": [1650.0, 62.52], - "ladder_rating": [1650.0, 62.52], - "number_of_games": 2 } assert msg == { "command": "welcome", diff --git a/tests/integration_tests/test_teammatchmaker.py b/tests/integration_tests/test_teammatchmaker.py index f2445730e..50c1e7368 100644 --- a/tests/integration_tests/test_teammatchmaker.py +++ b/tests/integration_tests/test_teammatchmaker.py @@ -610,9 +610,6 @@ async def test_ratings_initialized_based_on_global(lobby_server): "number_of_games": 5 } }, - "global_rating": [2000.0, 125.0], - "ladder_rating": [2000.0, 125.0], - "number_of_games": 5, } ] } @@ -651,9 +648,6 @@ async def test_ratings_initialized_based_on_global(lobby_server): "number_of_games": 0 } }, - "global_rating": [2000.0, 125.0], - "ladder_rating": [2000.0, 125.0], - "number_of_games": 5, } diff --git a/tests/unit_tests/test_players.py b/tests/unit_tests/test_players.py index d03ad99c4..22d8f9144 100644 --- a/tests/unit_tests/test_players.py +++ b/tests/unit_tests/test_players.py @@ -101,9 +101,6 @@ def test_serialize(): "number_of_games": 0 } }, - "global_rating": (1234, 68), - "ladder_rating": (1500, 230), - "number_of_games": 542, }