diff --git a/IPython/core/tests/test_magic.py b/IPython/core/tests/test_magic.py index 01081eb..5133e94 100644 --- a/IPython/core/tests/test_magic.py +++ b/IPython/core/tests/test_magic.py @@ -420,13 +420,13 @@ def test_extension(): def test_notebook_export_json(): with TemporaryDirectory() as td: outfile = os.path.join(td, "nb.ipynb") - _ip.ex(py3compat.u_format("u = {u}'héllo'")) + _ip.ex(py3compat.u_format(u"u = {u}'héllo'")) _ip.magic("notebook -e %s" % outfile) def test_notebook_export_py(): with TemporaryDirectory() as td: outfile = os.path.join(td, "nb.py") - _ip.ex(py3compat.u_format("u = {u}'héllo'")) + _ip.ex(py3compat.u_format(u"u = {u}'héllo'")) _ip.magic("notebook -e %s" % outfile) def test_notebook_reformat_py(): @@ -435,7 +435,7 @@ def test_notebook_reformat_py(): with io.open(infile, 'w') as f: current.write(nb0, f, 'json') - _ip.ex(py3compat.u_format("u = {u}'héllo'")) + _ip.ex(py3compat.u_format(u"u = {u}'héllo'")) _ip.magic("notebook -f py %s" % infile) def test_notebook_reformat_json(): @@ -444,7 +444,7 @@ def test_notebook_reformat_json(): with io.open(infile, 'w') as f: current.write(nb0, f, 'py') - _ip.ex(py3compat.u_format("u = {u}'héllo'")) + _ip.ex(py3compat.u_format(u"u = {u}'héllo'")) _ip.magic("notebook -f ipynb %s" % infile) _ip.magic("notebook -f json %s" % infile)