shithub: aubio

Download patch

ref: 18d8bef994bf262a0056d72e4ad1d793b7844075
parent: 2eccf22c76ecb7e80b3d1678147b0451cee34ad5
author: Paul Brossier <piem@piem.org>
date: Sun Feb 23 09:21:25 EST 2014

python/tests/utils.py: add get_tmp_sink_name

--- a/python/tests/utils.py
+++ b/python/tests/utils.py
@@ -19,6 +19,13 @@
     else:
         return all_sounds[0]
 
+def get_tmp_sink_name():
+    from tempfile import mkstemp
+    import os
+    fd, name = mkstemp()
+    os.close(fd)
+    return name
+
 def array_from_yaml_file(filename):
     import yaml
     f = open(filename)