diff options
author | Max Romanov <max.romanov@nginx.com> | 2020-10-05 13:26:35 +0300 |
---|---|---|
committer | Max Romanov <max.romanov@nginx.com> | 2020-10-05 13:26:35 +0300 |
commit | 481e950b8696740397eeda0d3c01a2dda2239143 (patch) | |
tree | 5b16ea71ec015c7443843886560d6da660f22be8 | |
parent | 58cc73994f071fc5db3347a3956f8089cb8e4dd0 (diff) | |
download | unit-481e950b8696740397eeda0d3c01a2dda2239143.tar.gz unit-481e950b8696740397eeda0d3c01a2dda2239143.tar.bz2 |
Tests: pretty versions output for multi-version tests.
-rw-r--r-- | test/conftest.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/conftest.py b/test/conftest.py index 8e9009b6..0bc5cdf9 100644 --- a/test/conftest.py +++ b/test/conftest.py @@ -74,11 +74,11 @@ def pytest_generate_tests(metafunc): def generate_tests(versions): metafunc.fixturenames.append('tmp_ct') - metafunc.parametrize('tmp_ct', range(len(versions))) + metafunc.parametrize('tmp_ct', versions) - for i, version in enumerate(versions): + for version in versions: option.generated_tests[ - metafunc.function.__name__ + '[{}]'.format(i) + metafunc.function.__name__ + '[{}]'.format(version) ] = (type + ' ' + version) # take available module from option and generate tests for each version |