telemetry-analysis-service/tests/test_names.py

13 строки
351 B
Python
Исходник Обычный вид История

import pytest
from atmo import names
2019-01-16 15:55:23 +03:00
@pytest.mark.parametrize("separator", ["-", "_"])
def test_names(separator):
name = names.random_scientist(separator=separator)
adjective, noun, suffix = name.split(separator)
assert adjective in names.adjectives
assert noun in names.scientists
assert len(suffix) == 4
assert int(suffix)