-
Notifications
You must be signed in to change notification settings - Fork 312
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix exception types in arcade.sound (#1926)
* Replace ValueError with more correct TypeError in arcade.stop_sound * Replace Exception with TypeError in arcade.play_sound * Improve clarity of play_sound exceptions * Add value echoing for all types * Only print load_sound recommendation on the most common errors. * Rename sound test function to be more specific * Use repr value for TypeError message in play_sound * Add test for play_sound TypeErrors * Add tests for arcade.stop_sound TypeErrors * Raise FileNotFoundError from the prior exception in load_sound * Improve stop_sound exception clarity * Shorten stop_sound * Indent align / visually clarify play_sound * Remove extra f-string line
- Loading branch information
Showing
2 changed files
with
48 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters