From 4b67a9a73a38750368c364b388d2a67650e94dab Mon Sep 17 00:00:00 2001 From: Tom Augspurger Date: Tue, 19 Nov 2019 09:43:26 -0600 Subject: [PATCH] TST: Silence lzma output This was leaking to stdout when the pytest `-s` flag was used. --- pandas/tests/io/test_compression.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pandas/tests/io/test_compression.py b/pandas/tests/io/test_compression.py index d68b6a1effaa0..9bcdda2039458 100644 --- a/pandas/tests/io/test_compression.py +++ b/pandas/tests/io/test_compression.py @@ -140,7 +140,7 @@ def test_with_missing_lzma(): import pandas """ ) - subprocess.check_output([sys.executable, "-c", code]) + subprocess.check_output([sys.executable, "-c", code], stderr=subprocess.PIPE) def test_with_missing_lzma_runtime(): @@ -157,4 +157,4 @@ def test_with_missing_lzma_runtime(): df.to_csv('foo.csv', compression='xz') """ ) - subprocess.check_output([sys.executable, "-c", code]) + subprocess.check_output([sys.executable, "-c", code], stderr=subprocess.PIPE)