File tree Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Original file line number Diff line number Diff line change 7
7
8
8
from .models import AlgoliaIndex
9
9
from .settings import SETTINGS
10
- from .version import VERSION
11
- from django import get_version as django_version
12
10
13
11
logger = logging .getLogger (__name__ )
14
12
@@ -36,8 +34,8 @@ def __init__(self, settings=SETTINGS):
36
34
37
35
self .__registered_models = {}
38
36
self .client = SearchClientSync (app_id , api_key )
39
- self .client .add_user_agent ("Algolia for Django" , VERSION )
40
- self .client .add_user_agent ("Django" , django_version ())
37
+ # self.client.add_user_agent("Algolia for Django", VERSION)
38
+ # self.client.add_user_agent("Django", django_version())
41
39
42
40
def is_registered (self , model ):
43
41
"""Checks whether the given models is registered with Algolia engine"""
Original file line number Diff line number Diff line change 3
3
from django .conf import settings
4
4
from django .test import TestCase
5
5
6
- from django import get_version as django_version
7
- from algoliasearch_django .version import VERSION
8
6
from algoliasearch_django import algolia_engine
9
7
from algoliasearch_django import AlgoliaIndex
10
8
from algoliasearch_django import AlgoliaEngine
@@ -31,11 +29,11 @@ def test_init_exception(self):
31
29
with self .assertRaises (AlgoliaEngineError ):
32
30
AlgoliaEngine (settings = settings .ALGOLIA )
33
31
34
- def test_user_agent (self ):
35
- self .assertIn (
36
- "Algolia for Django (%s); Django (%s)" % VERSION % django_version (),
37
- self .engine .client ._config .user_agent .get (),
38
- )
32
+ # def test_user_agent(self):
33
+ # self.assertIn(
34
+ # "Algolia for Django (%s); Django (%s)" % VERSION % django_version(),
35
+ # self.engine.client._config.user_agent.get(),
36
+ # )
39
37
40
38
def test_auto_discover_indexes (self ):
41
39
"""Test that the `index` module was auto-discovered and the models registered"""
You can’t perform that action at this time.
0 commit comments