test_synonyms.py 330 B

123456789101112131415161718192021
  1. import json
  2. import pytest
  3. import word_processor.generators.synonym as synonym
  4. @pytest.mark.parametrize(
  5. 'word',
  6. [
  7. 'dog',
  8. 'cat',
  9. 'fetcher',
  10. 'serializer',
  11. 'factory',
  12. ]
  13. )
  14. def test_synonyms(snapshot, word):
  15. result = synonym.get_synonyms(word)
  16. assert result == snapshot