Skip to content

Commit 112512c

Browse files
committed
Make hatch happy with re-building javascript within subprocesses
1 parent da62c03 commit 112512c

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

tests/conftest.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@ def pytest_addoption(parser) -> None:
1919

2020
def pytest_sessionstart(session):
2121
"""Rebuild the project before running the tests to get the latest JavaScript"""
22-
subprocess.run(["hatch", "build", "--clean"], check=True)
22+
env = os.environ.copy()
23+
env.pop("HATCH_ENV_ACTIVE", None)
24+
subprocess.run(["hatch", "build", "--clean"], check=True, env=env)
2325
subprocess.run(["playwright", "install", "chromium"], check=True)
2426

2527

0 commit comments

Comments
 (0)