зеркало из https://github.com/mozilla/taar.git
Force the client_id to exist in the results from ProfileFetcher.
This commit is contained in:
Родитель
b5f0d6282c
Коммит
1fc30c0f91
|
@ -22,6 +22,7 @@ class ProfileFetcher(object):
|
|||
if not addon.get('is_system', False)]
|
||||
|
||||
return {
|
||||
"client_id": client_id,
|
||||
"geo_city": profile_data.get("city", ''),
|
||||
"subsession_length": profile_data.get("subsession_length", 0),
|
||||
"locale": profile_data.get('locale', ''),
|
||||
|
|
|
@ -28,6 +28,7 @@ def test_profile_fetcher_returns_dict():
|
|||
# Note that active_addons in the raw JSON source is remapped to
|
||||
# 'installed_addons'
|
||||
assert fetcher.get("random-client-id") == {
|
||||
"client_id": 'random-client-id',
|
||||
"bookmark_count": 0,
|
||||
"disabled_addons_ids": [],
|
||||
"geo_city": "Rome",
|
||||
|
|
Загрузка…
Ссылка в новой задаче