Skip to content

Commit

Permalink
Merge pull request #7526 from bluetech/win-bash-2
Browse files Browse the repository at this point in the history
testing: improve bash check
  • Loading branch information
nicoddemus committed Jul 22, 2020
2 parents dbc50a7 + 0709305 commit 2a8dcc9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions testing/test_parseopt.py
Expand Up @@ -292,10 +292,11 @@ def test_argcomplete(testdir, monkeypatch) -> None:
bash_version = subprocess.run(
["bash", "--version"],
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
stderr=subprocess.DEVNULL,
check=True,
universal_newlines=True,
).stdout
except OSError:
except (OSError, subprocess.CalledProcessError):
pytest.skip("bash is not available")
if "GNU bash" not in bash_version:
# See #7518.
Expand Down

0 comments on commit 2a8dcc9

Please sign in to comment.