##// END OF EJS Templates
updated test for spaces in filename
Paul Ivanov -
Show More
@@ -76,17 +76,18 b' class TestNbConvertApp(TestsBase):'
76 assert os.path.isfile('notebook2.py')
76 assert os.path.isfile('notebook2.py')
77
77
78
78
79 @dec.onlyif_cmds_exist('pdflatex')
80 @dec.onlyif_cmds_exist('pandoc')
79 def test_filename_spaces(self):
81 def test_filename_spaces(self):
80 """
82 """
81 Are spaces removed from filenames?
83 Generate PDFs with graphics if notebooks have spaces in the name?
82 """
84 """
83 with self.create_temp_cwd(['notebook1.ipynb']):
85 with self.create_temp_cwd(['notebook1.ipynb']):
84 os.rename('notebook1.ipynb', 'notebook with spaces.ipynb')
86 os.rename('notebook1.ipynb', 'notebook with spaces.ipynb')
85 self.call('nbconvert --log-level=0 --to="latex" "notebook with spaces"')
87 self.call('nbconvert --log-level=0 --to="latex" "notebook with spaces"')
86 assert os.path.isfile('notebook with spaces.tex')
88 assert os.path.isfile('notebook with spaces.tex')
87 assert os.path.isdir('notebook_with_spaces_files')
89 assert os.path.isdir('notebook with spaces_files')
88 for f in glob.glob('notebook_with_spaces_files/*'):
90 assert os.path.isfile('notebook with spaces.pdf')
89 assert r" \t\n" not in f
90
91
91 @dec.onlyif_cmds_exist('pdflatex')
92 @dec.onlyif_cmds_exist('pdflatex')
92 @dec.onlyif_cmds_exist('pandoc')
93 @dec.onlyif_cmds_exist('pandoc')
General Comments 0
You need to be logged in to leave comments. Login now