We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0113530 commit 137aea6Copy full SHA for 137aea6
tests/config_loader/basic_test.py
@@ -1,4 +1,5 @@
1
# coding: utf-8
2
+from scraper.src.config.version import __version__, qualified_version
3
from scraper.src.config.config_loader import ConfigLoader
4
from .abstract import config
5
import pytest
@@ -48,3 +49,14 @@ def test_excpetion_when_shadowing_(self):
48
49
50
with pytest.raises(Exception):
51
ConfigLoader(c)
52
+
53
+ def test_get_qualified_version(self):
54
+ """ Old variable scrap_url must be spread to scrape_url. If one is defined, the previous one must be used"""
55
+ # Given
56
+ c = config({
57
+ 'user_agent': qualified_version()
58
+ })
59
60
+ config_loaded = ConfigLoader(c)
61
62
+ assert config_loaded.user_agent == f"Meilisearch DocsScraper (v{__version__})"
0 commit comments