Skip to content

Commit

Permalink
stubs addition and fixing mp3 test
Browse files Browse the repository at this point in the history
  • Loading branch information
Borishkof committed Nov 28, 2024
1 parent 726244d commit 4bfd1e8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
2 changes: 2 additions & 0 deletions buildconfig/stubs/pygame/mixer.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ class Sound:
def get_num_channels(self) -> int: ...
def get_length(self) -> float: ...
def get_raw(self) -> bytes: ...
def copy(self) -> Sound: ...
def __copy__(self) -> Sound: ...


class Channel:
Expand Down
11 changes: 3 additions & 8 deletions test/mixer_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -714,14 +714,9 @@ def test_get_sdl_mixer_version__linked_equals_compiled(self):
def test_snd_copy(self):
mixer.init()

filenames = [
"house_lo.mp3",
"house_lo.ogg",
"house_lo.wav",
"house_lo.flac",
# "house_lo.opus", unsupported
# "surfonasinewave.xm" unsupported
]
filenames = ["house_lo.ogg", "house_lo.wav", "house_lo.flac"]
if pygame.mixer.get_sdl_mixer_version() >= (2, 6, 0):
filenames.append("house_lo.mp3")

for f in filenames:
filename = example_path(os.path.join("data", f))
Expand Down

0 comments on commit 4bfd1e8

Please sign in to comment.