From 9b223849e889adb162504b7ee7ab630a0dacabba Mon Sep 17 00:00:00 2001 From: Eddy Pedroni Date: Thu, 28 May 2026 12:11:43 +0200 Subject: Improve tests --- solo-tool-project/test/solo_tool_songs_integrationtest.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/solo-tool-project/test/solo_tool_songs_integrationtest.py b/solo-tool-project/test/solo_tool_songs_integrationtest.py index caa4a30..2c62bba 100644 --- a/solo-tool-project/test/solo_tool_songs_integrationtest.py +++ b/solo-tool-project/test/solo_tool_songs_integrationtest.py @@ -42,14 +42,19 @@ def test_songSelectionEdgeCases(uut, mockPlayer, testSongs): assert uut.song == 0 assert mockPlayer.currentSong == testSongs[0] + uut.song = 1 + uut.song = None + assert uut.song == 1 + assert mockPlayer.currentSong == testSongs[1] + # Non-existent songs cannot be selected uut.song = -1 - assert uut.song == 0 - assert mockPlayer.currentSong == testSongs[0] + assert uut.song == 1 + assert mockPlayer.currentSong == testSongs[1] uut.song = len(testSongs) - assert uut.song == 0 - assert mockPlayer.currentSong == testSongs[0] + assert uut.song == 1 + assert mockPlayer.currentSong == testSongs[1] def test_songAdditionEdgeCases(uut, mockPlayer, testSongs): for song in testSongs: -- cgit v1.2.3