Skip to content

Commit

Permalink
Fix mistake in merging pyodide#1047 and pyodide#1083 (pyodide#1121)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hood Chatham authored Jan 11, 2021
1 parent 3548683 commit 3635b88
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pyodide_build/testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,13 @@ def inner(selenium):
# containing the source. This results in a more helpful
# traceback
selenium.run_js(
"""pyodide._module.pyodide_py.eval_code({!r}, pyodide._module.globals, "last_expr", true, {!r})""".format(
"""pyodide._module.pyodide_py.eval_code({!r}, // code
pyodide._module.globals, // globals
pyodide._module.globals, // locals
"last_expr", // return_mode
true, // quiet_trailing_semicolon
{!r} // filename
)""".format(
source, inspect.getsourcefile(f)
)
)
Expand Down
6 changes: 6 additions & 0 deletions src/tests/test_testing.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
import pathlib
from pyodide_build.testing import run_in_pyodide


def test_web_server_secondary(selenium, web_server_secondary):
host, port, logs = web_server_secondary
assert pathlib.Path(logs).exists()
assert selenium.server_port != port


@run_in_pyodide
def test_run_in_pyodide():
pass

0 comments on commit 3635b88

Please sign in to comment.