Support OpenBSD and NetBSD

This commit is contained in:
Ivan Zaikin
2020-07-28 08:55:32 +07:00
parent 3312dcde61
commit e528a42ddc
2 changed files with 2 additions and 9 deletions

View File

@@ -6,11 +6,7 @@ import pytest
def auto_detect_cpus():
try:
n = psutil.cpu_count(logical=False)
except NotImplementedError:
return 1
return n if n else 1
return psutil.cpu_count(logical=False) or psutil.cpu_count() or 1
class AutoInt(int):