mirror of https://github.com/pyodide/pyodide.git
parent
9389a042ed
commit
f352fd34fb
|
@ -29,13 +29,13 @@ def test_snapshot_simple(selenium_standalone_noload):
|
|||
const py1 = await loadPyodide({_makeSnapshot: true});
|
||||
py1.runPython(`
|
||||
from js import Headers, URL
|
||||
canParse = URL.canParse
|
||||
createObjectURL = URL.createObjectURL
|
||||
`);
|
||||
const snapshot = py1.makeMemorySnapshot();
|
||||
const py2 = await loadPyodide({_loadSnapshot: snapshot});
|
||||
assert(() => py2.globals.get("Headers") === Headers);
|
||||
assert(() => py2.globals.get("URL") === URL);
|
||||
assert(() => py2.globals.get("canParse") === URL.canParse);
|
||||
assert(() => py2.globals.get("createObjectURL") === URL.createObjectURL);
|
||||
"""
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in New Issue