tests/integration/test_execute: use plain Python rather than xxd
Removes this test's dependencies on vim and /dev/urandom. Signed-off-by: Marek Szuba <marek.szuba@cern.ch>
This commit is contained in:
parent
92d729a9dd
commit
e8b8d86592
1 changed files with 3 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
||||||
import logging
|
import logging
|
||||||
import subprocess
|
import subprocess
|
||||||
|
import sys
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from flexmock import flexmock
|
from flexmock import flexmock
|
||||||
|
@ -134,7 +135,8 @@ def test_log_outputs_vents_other_processes_when_one_exits():
|
||||||
flexmock(module).should_receive('command_for_process').and_return('grep')
|
flexmock(module).should_receive('command_for_process').and_return('grep')
|
||||||
|
|
||||||
process = subprocess.Popen(
|
process = subprocess.Popen(
|
||||||
['xxd', '-l', '40000', '-p', '/dev/urandom'], stdout=subprocess.PIPE, stderr=subprocess.PIPE
|
[sys.executable, '-c', "import random, string; print(''.join(random.choice(string.ascii_letters) for _ in range(40000)))"],
|
||||||
|
stdout=subprocess.PIPE, stderr=subprocess.PIPE
|
||||||
)
|
)
|
||||||
other_process = subprocess.Popen(
|
other_process = subprocess.Popen(
|
||||||
['true'], stdin=process.stdout, stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
['true'], stdin=process.stdout, stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
||||||
|
|
Loading…
Reference in a new issue