projects
/
aubio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e987c05
)
python/tests/utils.py: add array_from_yaml_file
author
Paul Brossier
<piem@piem.org>
Wed, 10 Apr 2013 05:28:51 +0000
(
00:28
-0500)
committer
Paul Brossier
<piem@piem.org>
Wed, 10 Apr 2013 05:28:51 +0000
(
00:28
-0500)
python/tests/utils.py
patch
|
blob
|
history
diff --git
a/python/tests/utils.py
b/python/tests/utils.py
index fa4dc44fbd0903751e8d4dfb3c3c0348e9d51a20..fda8cb79258df97cf19931b2bcc78eb4cb9a4812 100644
(file)
--- a/
python/tests/utils.py
+++ b/
python/tests/utils.py
@@
-11,3
+11,10
@@
def list_all_sounds(rel_dir):
import os.path, glob
datadir = os.path.join(os.path.dirname(__file__), rel_dir)
return glob.glob(os.path.join(datadir,'*.*'))
+
+def array_from_yaml_file(filename):
+ import yaml
+ f = open(filename)
+ yaml_data = yaml.safe_load(f)
+ f.close()
+ return yaml_data