udata 9.1.3.dev30846__py2.py3-none-any.whl → 9.1.3.dev30862__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of udata might be problematic. Click here for more details.
- udata/commands/fixtures.py +4 -4
- udata/commands/tests/test_fixtures.py +3 -1
- {udata-9.1.3.dev30846.dist-info → udata-9.1.3.dev30862.dist-info}/METADATA +1 -1
- {udata-9.1.3.dev30846.dist-info → udata-9.1.3.dev30862.dist-info}/RECORD +8 -8
- {udata-9.1.3.dev30846.dist-info → udata-9.1.3.dev30862.dist-info}/LICENSE +0 -0
- {udata-9.1.3.dev30846.dist-info → udata-9.1.3.dev30862.dist-info}/WHEEL +0 -0
- {udata-9.1.3.dev30846.dist-info → udata-9.1.3.dev30862.dist-info}/entry_points.txt +0 -0
- {udata-9.1.3.dev30846.dist-info → udata-9.1.3.dev30862.dist-info}/top_level.txt +0 -0
udata/commands/fixtures.py
CHANGED
|
@@ -39,9 +39,8 @@ COMMUNITY_RES_URL = "/api/1/datasets/community_resources"
|
|
|
39
39
|
DISCUSSION_URL = "/api/1/discussions"
|
|
40
40
|
|
|
41
41
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
)
|
|
42
|
+
DEFAULT_FIXTURE_FILE_TAG: str = "v1.0.0"
|
|
43
|
+
DEFAULT_FIXTURE_FILE: str = f"https://raw.githubusercontent.com/opendatateam/udata-fixtures/{DEFAULT_FIXTURE_FILE_TAG}/results.json" # noqa
|
|
45
44
|
|
|
46
45
|
DEFAULT_FIXTURES_RESULTS_FILENAME: str = "results.json"
|
|
47
46
|
|
|
@@ -199,7 +198,8 @@ def import_fixtures(source):
|
|
|
199
198
|
MessageDiscussionFactory(**message, posted_by=user) for message in messages
|
|
200
199
|
],
|
|
201
200
|
)
|
|
202
|
-
for dataservice in fixture
|
|
201
|
+
for dataservice in fixture.get("dataservices", []):
|
|
202
|
+
# We may be missing dataservices in older fixtures.
|
|
203
203
|
dataservice = remove_unwanted_keys(dataservice, "dataservice")
|
|
204
204
|
if not dataservice["contact_point"]:
|
|
205
205
|
DataserviceFactory(**dataservice, datasets=[dataset])
|
|
@@ -7,6 +7,7 @@ import werkzeug.test
|
|
|
7
7
|
from pytest_mock import MockerFixture
|
|
8
8
|
from werkzeug.wrappers.response import Response
|
|
9
9
|
|
|
10
|
+
import udata.commands.fixtures
|
|
10
11
|
from udata import models
|
|
11
12
|
from udata.core.dataservices.factories import DataserviceFactory
|
|
12
13
|
from udata.core.dataset.factories import (
|
|
@@ -69,4 +70,5 @@ class FixturesTest:
|
|
|
69
70
|
assert models.Dataset.objects.count() > 0
|
|
70
71
|
assert models.Reuse.objects.count() > 0
|
|
71
72
|
assert models.User.objects.count() > 0
|
|
72
|
-
|
|
73
|
+
if udata.commands.fixtures.DEFAULT_FIXTURE_FILE_TAG > "v1.0.0":
|
|
74
|
+
assert models.Dataservice.objects.count() > 0
|
|
@@ -42,7 +42,7 @@ udata/commands/__init__.py,sha256=Won_rW_hIU9TA3o4oNe6kI46l1fnDBM_oW0Hc1XS9F8,77
|
|
|
42
42
|
udata/commands/cache.py,sha256=bLdrf_fCWFYX9ULlL2ADsZRwijkI4pArsJxfx24OivM,341
|
|
43
43
|
udata/commands/db.py,sha256=64x0614tCUl2f-c6b9K_TcRMyydZCnmCWrz5WI6tUkg,14701
|
|
44
44
|
udata/commands/dcat.py,sha256=L1BTywlHFBOkddZnKfWr8P4QjRMZksYCwhUNfJv5tkc,3409
|
|
45
|
-
udata/commands/fixtures.py,sha256=
|
|
45
|
+
udata/commands/fixtures.py,sha256=YPG47m1ch6E-5US1TfQKbalZZDhSRBDwuVfWHiQPWuU,8445
|
|
46
46
|
udata/commands/images.py,sha256=0rVojLik5DYgJ6W4uNEfMP2g2QUU2V761tj3z6lo8no,2050
|
|
47
47
|
udata/commands/info.py,sha256=A5WMo3_N_rlt3cySVJrZqKWrbIowX97ZLKMIFQE5178,1545
|
|
48
48
|
udata/commands/init.py,sha256=8CpH8MklzPkpxczs43lFM5ZNrHCJRbUtzHapgYNHs7M,1520
|
|
@@ -52,7 +52,7 @@ udata/commands/static.py,sha256=OUYPAR1giaPk52DK-v-nQYUSx-YQ4cF7YXLt1t5wtBU,2199
|
|
|
52
52
|
udata/commands/test.py,sha256=0snHTDolowQK-DmAKnhF_mBuDOBMApAbEc35GEiwH0M,893
|
|
53
53
|
udata/commands/worker.py,sha256=bjXQGCwkbZxkcxLMPA2Lr0nkNjXLpGNDMkkQXjwBLPI,3976
|
|
54
54
|
udata/commands/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
55
|
-
udata/commands/tests/test_fixtures.py,sha256=
|
|
55
|
+
udata/commands/tests/test_fixtures.py,sha256=7gZSyiqrn6G84tZ1koPkgnYwnrskmZaqjRTXEPmnA9s,3326
|
|
56
56
|
udata/core/__init__.py,sha256=O7C9WWCXiLWnWPnPbFRszWhOmvRQiI4gD-5qkWvPGRo,385
|
|
57
57
|
udata/core/owned.py,sha256=xcIg9fNndowuLs7BEkuxAsEdf6JApomU_Gl6L-SgTJI,4515
|
|
58
58
|
udata/core/activity/__init__.py,sha256=OaiFyq7HB4xL4SuMPD1N8IFNpntwx9ZayVzelciOieI,298
|
|
@@ -697,9 +697,9 @@ udata/translations/pt/LC_MESSAGES/udata.mo,sha256=WpPzAqVd2Onv_kz45ULUySKPLrpjcc
|
|
|
697
697
|
udata/translations/pt/LC_MESSAGES/udata.po,sha256=18Op9RUITewoDRewlOdYzzq6gjsf1lsvepACV1d7zxs,44976
|
|
698
698
|
udata/translations/sr/LC_MESSAGES/udata.mo,sha256=NIYRNhVoETZUvIvWm3cCW7DtMBAnS2vXzZjMF5ZzD_c,28500
|
|
699
699
|
udata/translations/sr/LC_MESSAGES/udata.po,sha256=rQB-4V4WJ7bURj6g2j653vItr5TMHadcLQxec7_fDmg,51545
|
|
700
|
-
udata-9.1.3.
|
|
701
|
-
udata-9.1.3.
|
|
702
|
-
udata-9.1.3.
|
|
703
|
-
udata-9.1.3.
|
|
704
|
-
udata-9.1.3.
|
|
705
|
-
udata-9.1.3.
|
|
700
|
+
udata-9.1.3.dev30862.dist-info/LICENSE,sha256=V8j_M8nAz8PvAOZQocyRDX7keai8UJ9skgmnwqETmdY,34520
|
|
701
|
+
udata-9.1.3.dev30862.dist-info/METADATA,sha256=WQh0lkuWrRA00-o_fzI5JU_oBExbSL5MtFwW9cMg2g0,127825
|
|
702
|
+
udata-9.1.3.dev30862.dist-info/WHEEL,sha256=DZajD4pwLWue70CAfc7YaxT1wLUciNBvN_TTcvXpltE,110
|
|
703
|
+
udata-9.1.3.dev30862.dist-info/entry_points.txt,sha256=3SKiqVy4HUqxf6iWspgMqH8d88Htk6KoLbG1BU-UddQ,451
|
|
704
|
+
udata-9.1.3.dev30862.dist-info/top_level.txt,sha256=39OCg-VWFWOq4gCKnjKNu-s3OwFlZIu_dVH8Gl6ndHw,12
|
|
705
|
+
udata-9.1.3.dev30862.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|