diff --git a/tests/test_notebooks.py b/tests/test_notebooks.py index 9d3d5b1f..b5817d7d 100644 --- a/tests/test_notebooks.py +++ b/tests/test_notebooks.py @@ -4,8 +4,6 @@ import tempfile from test_helpers import timer -import nbformat - notebook_dir = os.path.abspath(os.path.join( os.path.split(os.path.abspath(__file__))[0], '..', @@ -18,6 +16,7 @@ def _notebook_run(path): """Execute a notebook via nbconvert and collect output. :returns (parsed nb object, execution errors) """ + import nbformat dirname, __ = os.path.split(path) os.chdir(dirname) with tempfile.NamedTemporaryFile(suffix=".ipynb") as fout: