Add test cases involving random data

This commit is contained in:
Kristóf Tóth 2018-12-16 21:42:54 +01:00
parent d28ea355f7
commit dd78a0af25

View File

@ -2,6 +2,7 @@
from os import stat from os import stat
from os.path import exists, dirname, realpath, join from os.path import exists, dirname, realpath, join
from stat import S_ISFIFO from stat import S_ISFIFO
from secrets import token_urlsafe
import pytest import pytest
@ -32,11 +33,14 @@ def test_pipes_isfifo(pipe_io):
@pytest.mark.parametrize( @pytest.mark.parametrize(
'test_data', [ 'test_data', [
'cats', 'Cats and cheese',
'cheese',
'You ever wonder why we are here?', 'You ever wonder why we are here?',
'Lorem ipsum dolor sit amet', 'Lorem ipsum dolor sit amet',
'You always have a plan, Dutch!' 'You always have a plan, Dutch!',
token_urlsafe(32),
token_urlsafe(32),
token_urlsafe(32),
token_urlsafe(32)
] ]
) )
def test_echo_server(pipe_io, test_data): def test_echo_server(pipe_io, test_data):