Commit 5335034d authored by Dan Pascu's avatar Dan Pascu

Simplified test

parent d0f98acb
...@@ -66,7 +66,7 @@ class CustomSoundFile(object): ...@@ -66,7 +66,7 @@ class CustomSoundFile(object):
def __init__(self, path=DefaultPath, volume=100): def __init__(self, path=DefaultPath, volume=100):
self.path = path self.path = path
self.volume = int(volume) self.volume = int(volume)
if self.volume < 0 or self.volume > 100: if not (0 <= self.volume <= 100):
raise ValueError('illegal volume level: %d' % self.volume) raise ValueError('illegal volume level: %d' % self.volume)
def __getstate__(self): def __getstate__(self):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment