[plotting_tests] failed, because of same name?

This commit is contained in:
mzwiessele 2015-11-07 10:46:17 +00:00
parent 8f194652a7
commit 0c11ba0bf8
43 changed files with 8 additions and 4 deletions

View file

@ -49,7 +49,10 @@ def read_to_rst(fname):
try:
import pypandoc
rstname = "{}.{}".format(os.path.splitext(fname)[0], 'rst')
return pypandoc.convert(read(fname), 'rst', format='md')
rststr = pypandoc.convert(read(fname), 'rst', format='md')
with open(rstname, 'w') as f:
f.write(rststr)
return rststr
#return read(rstname)
except ImportError:
return read(fname)