diff --git a/IPython/nbconvert/transformers/tests/test_coalescestreams.py b/IPython/nbconvert/transformers/tests/test_coalescestreams.py index 7dc9be2..c33ce86 100644 --- a/IPython/nbconvert/transformers/tests/test_coalescestreams.py +++ b/IPython/nbconvert/transformers/tests/test_coalescestreams.py @@ -27,7 +27,10 @@ class TestCoalesceStreams(TransformerTestsBase): def test_coalesce_streams(self): """coalesce_streams transformer output test""" - nb, res = coalesce_streams(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + nb, res = transformer(nb, res) + nb, res = coalesce_streams(nb, res) outputs = nb.worksheets[0].cells[0].outputs self.assertEqual(outputs[0].text, "a") self.assertEqual(outputs[1].output_type, "text") diff --git a/IPython/nbconvert/transformers/tests/test_csshtmlheader.py b/IPython/nbconvert/transformers/tests/test_csshtmlheader.py index 6183e12..709e3af 100644 --- a/IPython/nbconvert/transformers/tests/test_csshtmlheader.py +++ b/IPython/nbconvert/transformers/tests/test_csshtmlheader.py @@ -40,6 +40,9 @@ class TestCSSHTMLHeader(TransformerTestsBase): def test_output(self): """Test the output of the CSSHTMLHeaderTransformer""" - nb, res = self.build_transformer()(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + transformer = self.build_transformer() + nb, res = transformer(nb, res) assert 'inlining' in res assert 'css' in res['inlining'] \ No newline at end of file diff --git a/IPython/nbconvert/transformers/tests/test_extractoutput.py b/IPython/nbconvert/transformers/tests/test_extractoutput.py index 58dcf27..21f93e6 100644 --- a/IPython/nbconvert/transformers/tests/test_extractoutput.py +++ b/IPython/nbconvert/transformers/tests/test_extractoutput.py @@ -40,7 +40,10 @@ class TestExtractOutput(TransformerTestsBase): def test_output(self): """Test the output of the ExtractOutputTransformer""" - nb, res = self.build_transformer()(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + transformer = self.build_transformer() + nb, res = transformer(nb, res) # Check if text was extracted. assert 'text_filename' in nb.worksheets[0].cells[0].outputs[1] diff --git a/IPython/nbconvert/transformers/tests/test_latex.py b/IPython/nbconvert/transformers/tests/test_latex.py index 663e8b6..ab0b274 100644 --- a/IPython/nbconvert/transformers/tests/test_latex.py +++ b/IPython/nbconvert/transformers/tests/test_latex.py @@ -39,7 +39,10 @@ class TestLatex(TransformerTestsBase): def test_output(self): """Test the output of the LatexTransformer""" - nb, res = self.build_transformer()(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + transformer = self.build_transformer() + nb, res = transformer(nb, res) # Make sure the code cell wasn't modified. self.assertEqual(nb.worksheets[0].cells[0].input, '$ e $') diff --git a/IPython/nbconvert/transformers/tests/test_revealhelp.py b/IPython/nbconvert/transformers/tests/test_revealhelp.py index 87b797a..126564e 100644 --- a/IPython/nbconvert/transformers/tests/test_revealhelp.py +++ b/IPython/nbconvert/transformers/tests/test_revealhelp.py @@ -60,14 +60,20 @@ class Testrevealhelp(TransformerTestsBase): def test_reveal_attribute(self): """Make sure the reveal url_prefix resources is set""" - nb, res = self.build_transformer()(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + transformer = self.build_transformer() + nb, res = transformer(nb, res) assert 'reveal' in res assert 'url_prefix' in res['reveal'] def test_reveal_output(self): """Make sure that the reveal transformer """ - nb, res = self.build_transformer()(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + transformer = self.build_transformer() + nb, res = transformer(nb, res) cells = nb.worksheets[0].cells # Make sure correct metadata tags are available on every cell. diff --git a/IPython/nbconvert/transformers/tests/test_sphinx.py b/IPython/nbconvert/transformers/tests/test_sphinx.py index f66b4a6..610c246 100644 --- a/IPython/nbconvert/transformers/tests/test_sphinx.py +++ b/IPython/nbconvert/transformers/tests/test_sphinx.py @@ -41,7 +41,10 @@ class TestSphinx(TransformerTestsBase): def test_resources(self): """Make sure the SphinxTransformer adds the appropriate resources to the resources dict.""" - nb, res = self.build_transformer()(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + transformer = self.build_transformer() + nb, res = transformer(nb, res) assert 'sphinx' in res assert "author" in res['sphinx'] assert "version" in res['sphinx'] diff --git a/IPython/nbconvert/transformers/tests/test_svg2pdf.py b/IPython/nbconvert/transformers/tests/test_svg2pdf.py index a008981..3914b54 100644 --- a/IPython/nbconvert/transformers/tests/test_svg2pdf.py +++ b/IPython/nbconvert/transformers/tests/test_svg2pdf.py @@ -78,10 +78,13 @@ class Testsvg2pdf(TransformerTestsBase): def test_constructor(self): """Can a SVG2PDFTransformer be constructed?""" self.build_transformer() - + @dec.onlyif_cmds_exist('inkscape') def test_output(self): """Test the output of the SVG2PDFTransformer""" - nb, res = self.build_transformer()(self.build_notebook(), self.build_resources()) + nb = self.build_notebook() + res = self.build_resources() + transformer = self.build_transformer() + nb, res = transformer(nb, res) assert 'svg' in nb.worksheets[0].cells[0].outputs[0]