Changeset 5d8cc71 for python/tests
- Timestamp:
- Aug 21, 2016, 12:45:04 PM (8 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
- Children:
- 857fe7ff
- Parents:
- 6a72ff0
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
python/tests/utils.py
r6a72ff0 r5d8cc71 5 5 import numpy as np 6 6 from tempfile import mkstemp 7 8 DEFAULT_SOUND = '22050Hz_5s_brownnoise.wav' 7 9 8 10 def array_from_text_file(filename, dtype = 'float'): … … 22 24 TestCase.skipTest("please add some sounds in \'python/tests/sounds\'") 23 25 else: 24 return all_sounds[0] 26 default_sound = all_sounds[0] 27 if DEFAULT_SOUND in map(os.path.basename, all_sounds): 28 while os.path.basename(default_sound) != DEFAULT_SOUND: 29 default_sound = all_sounds.pop(0) 30 return default_sound 25 31 26 32 def get_tmp_sink_path():
Note: See TracChangeset
for help on using the changeset viewer.