diff options
Diffstat (limited to 'packages/meshbay-hub/tests/test_indexing_dock.py')
| -rw-r--r-- | packages/meshbay-hub/tests/test_indexing_dock.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/packages/meshbay-hub/tests/test_indexing_dock.py b/packages/meshbay-hub/tests/test_indexing_dock.py index d69564d..93803a0 100644 --- a/packages/meshbay-hub/tests/test_indexing_dock.py +++ b/packages/meshbay-hub/tests/test_indexing_dock.py @@ -33,11 +33,11 @@ needs_node = pytest.mark.skipif(shutil.which("node") is None, reason="node is no def _run(tmp_path, body: str): - (tmp_path / "package.json").write_text('{"type":"module"}') - (tmp_path / "model.js").write_text(MODEL.read_text(encoding="utf-8")) + (tmp_path / "package.json").write_text('{"type":"module"}', encoding="utf-8") + (tmp_path / "model.js").write_text(MODEL.read_text(encoding="utf-8"), encoding="utf-8") script = tmp_path / "case.js" - script.write_text("import * as m from './model.js';\n" + body) - proc = subprocess.run(["node", str(script)], capture_output=True, text=True, + script.write_text("import * as m from './model.js';\n" + body, encoding="utf-8") + proc = subprocess.run(["node", str(script)], capture_output=True, text=True, encoding="utf-8", cwd=str(tmp_path)) assert proc.returncode == 0, proc.stderr return json.loads(proc.stdout) |