diff --git a/Client/test_profile_save.py b/Client/test_profile_save.py index a210a08..96a6f0c 100644 --- a/Client/test_profile_save.py +++ b/Client/test_profile_save.py @@ -2,6 +2,7 @@ from Client.profile_save import Profile import os from Server.player import Player +from os.path import exists class TestProfileSave(unittest.TestCase): @@ -16,6 +17,8 @@ def setUp(self): self.profile.delete_all_profiles() def test_all(self): + if exists(self.profile.path): + os.remove(self.profile.path) data = [self.player1, self.player2] self.profile.set_profiles(data) self.assertEqual(self.profile.get_profiles(), data)