mirror of https://github.com/pypa/pip
Merge a37ff041c9
into 2a0acb595c
This commit is contained in:
commit
764e6fb912
|
@ -0,0 +1 @@
|
|||
Suppress the progress bar, when running with ``--log`` and ``--quiet``.
|
|
@ -305,6 +305,9 @@ class RequirementCommand(IndexGroupCommand):
|
|||
"fast-deps has no effect when used with the legacy resolver."
|
||||
)
|
||||
|
||||
if options.quiet:
|
||||
options.progress_bar = "off"
|
||||
|
||||
return RequirementPreparer(
|
||||
build_dir=temp_build_dir_path,
|
||||
src_dir=options.src_dir,
|
||||
|
|
|
@ -580,6 +580,17 @@ def test_install_quiet(script: PipTestEnvironment, data: TestData) -> None:
|
|||
assert result.stderr == ""
|
||||
|
||||
|
||||
@pytest.mark.network
|
||||
def test_install_quiet_log(script: PipTestEnvironment, data: TestData) -> None:
|
||||
"""
|
||||
Test suppressing the progress bar with --quiet and --log.
|
||||
"""
|
||||
logfile = script.scratch_path / "log"
|
||||
result = script.pip("install", "-qqq", "setuptools==62.0.0", "--log", logfile)
|
||||
assert result.stdout == ""
|
||||
assert result.stderr == ""
|
||||
|
||||
|
||||
def test_hashed_install_success(
|
||||
script: PipTestEnvironment, data: TestData, tmpdir: Path
|
||||
) -> None:
|
||||
|
|
Loading…
Reference in New Issue