From 32e7306c6b88ebff8d1ad2bdc08b93aa34a99175 Mon Sep 17 00:00:00 2001 From: Marc Wouts Date: Sun, 14 Oct 2018 21:54:27 +0200 Subject: [PATCH] Comparison method depends on ext --- tests/test_contentsmanager.py | 2 +- tests/test_ipynb_to_rmd.py | 2 +- tests/test_save_multiple.py | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test_contentsmanager.py b/tests/test_contentsmanager.py index 1d0bae3eb..f0e70febb 100644 --- a/tests/test_contentsmanager.py +++ b/tests/test_contentsmanager.py @@ -34,7 +34,7 @@ def test_load_save_rename(nb_file, tmpdir): nb = jupytext.readf(nb_file) cm.save(model=dict(type='notebook', content=nb), path=tmp_rmd) nb_rmd = cm.get(tmp_rmd) - compare_notebooks(nb, nb_rmd['content']) + compare_notebooks(nb, nb_rmd['content'], ext='.Rmd') # save ipynb cm.save(model=dict(type='notebook', content=nb), path=tmp_ipynb) diff --git a/tests/test_ipynb_to_rmd.py b/tests/test_ipynb_to_rmd.py index 1d897c271..ef04a95c7 100644 --- a/tests/test_ipynb_to_rmd.py +++ b/tests/test_ipynb_to_rmd.py @@ -22,4 +22,4 @@ def test_identity_source_write_read(nb_file): rmd = jupytext.writes(nb1, ext='.Rmd') nb2 = jupytext.reads(rmd, ext='.Rmd') - compare_notebooks(nb1, nb2) + compare_notebooks(nb1, nb2, ext='.Rmd') diff --git a/tests/test_save_multiple.py b/tests/test_save_multiple.py index fca2ae77d..be1b94dcb 100644 --- a/tests/test_save_multiple.py +++ b/tests/test_save_multiple.py @@ -28,7 +28,7 @@ def test_rmd_is_ok(nb_file, tmpdir): nb2 = jupytext.readf(str(tmpdir.join(tmp_rmd))) - compare_notebooks(nb, nb2) + compare_notebooks(nb, nb2, ext='.Rmd') @pytest.mark.parametrize('nb_file', list_notebooks('Rmd')) @@ -69,7 +69,7 @@ def test_all_files_created(nb_file, tmpdir): compare_notebooks(nb, nb2) nb3 = jupytext.readf(str(tmpdir.join(tmp_rmd))) - compare_notebooks(nb, nb3) + compare_notebooks(nb, nb3, ext='.Rmd') def test_no_files_created_on_no_format(tmpdir):