Пример #1
0
def test_sanitize_max_jobs_none():
  assert DEFAULT_MAX_JOBS == _sanitize_max_jobs(None)
Пример #2
0
def test_sanitize_max_jobs_too_large():
  assert _ABSOLUTE_MAX_JOBS == _sanitize_max_jobs(_ABSOLUTE_MAX_JOBS)
  assert _ABSOLUTE_MAX_JOBS == _sanitize_max_jobs(_ABSOLUTE_MAX_JOBS + 1)
  assert _ABSOLUTE_MAX_JOBS == _sanitize_max_jobs(_ABSOLUTE_MAX_JOBS + 5)
Пример #3
0
def test_sanitize_max_jobs_nominal():
  assert 1 == _sanitize_max_jobs(1)
Пример #4
0
def test_sanitize_max_jobs_less_then_one():
  assert DEFAULT_MAX_JOBS == _sanitize_max_jobs(0)
  assert DEFAULT_MAX_JOBS == _sanitize_max_jobs(-1)
  assert DEFAULT_MAX_JOBS == _sanitize_max_jobs(-5)
Пример #5
0
def test_sanitize_max_jobs_none():
    # type: () -> None
    assert DEFAULT_MAX_JOBS == _sanitize_max_jobs(None)
Пример #6
0
def test_sanitize_max_jobs_nominal():
    # type: () -> None
    assert 1 == _sanitize_max_jobs(1)