fix: make cupy installation opt-in
This commit is contained in:
1 parent
897e343268
commit
2ee1c6f4cf
3 files changed
+32
-37
No files matched your search
@@ -0,0 +1,19 @@
|
||||
import os
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
import install as tween_install
|
||||
|
||||
|
||||
def test_installer_never_installs_optional_cupy(monkeypatch):
|
||||
calls = []
|
||||
monkeypatch.setattr(subprocess, "check_call", calls.append)
|
||||
|
||||
tween_install.install()
|
||||
|
||||
requirements_path = os.path.join(
|
||||
os.path.dirname(tween_install.__file__), "requirements.txt"
|
||||
)
|
||||
assert calls == [[
|
||||
sys.executable, "-m", "pip", "install", "-r", requirements_path
|
||||
]]
|
||||
Reference in new issue
Block a user