mirror of
https://github.com/Cian-H/invenio-config-iform.git
synced 2025-12-22 13:11:56 +00:00
Updated test settings
This commit is contained in:
@@ -33,8 +33,8 @@ Issues = "https://github.com/Cian-H/invenio-config-iform/issues"
|
||||
tests = [
|
||||
"invenio-app>=1.5.0",
|
||||
"invenio-search[opensearch2]>=2.1.0,<3.0.0",
|
||||
"pytest-black-ng>=0.4.0",
|
||||
"pytest-invenio>=2.1.0,<3.0.0",
|
||||
"pytest-ruff>=0.4.1",
|
||||
"ruff>=0.5.3",
|
||||
"Sphinx>=4.5.0",
|
||||
]
|
||||
@@ -52,12 +52,12 @@ exclude = [".venv", "tests/*", "*/tests/*", "*.rst", "run-tests.sh"]
|
||||
|
||||
# Testing configuration
|
||||
[tool.pytest]
|
||||
addopts = "--black --isort --pydocstyle --doctest-glob=\"*.rst\" --doctest-modules --cov=invenio_config_iform --cov-report=term-missing tests invenio_config_iform"
|
||||
addopts = "--ruff --ruff-format --pydocstyle --doctest-glob=\"*.rst\" --doctest-modules --cov=invenio_config_iform --cov-report=term-missing tests invenio_config_iform"
|
||||
testpaths = ["tests", "invenio_config_iform"]
|
||||
live_server_scope = "module"
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
addopts = "--black --isort --pydocstyle --doctest-glob=\"*.rst\" --doctest-modules --cov=invenio_config_iform --cov-report=term-missing tests invenio_config_iform"
|
||||
addopts = "--ruff --ruff-format --pydocstyle --doctest-glob=\"*.rst\" --doctest-modules --cov=invenio_config_iform --cov-report=term-missing tests invenio_config_iform"
|
||||
testpaths = ["tests", "invenio_config_iform"]
|
||||
live_server_scope = "module"
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ def test_policies_synced() -> None:
|
||||
# check whether same set of `can_<action>`s`
|
||||
if extras := set(iform_cans) - set(rdm_cans) - ALLOWED_DIFFERENCES:
|
||||
msg = f"""
|
||||
TU Graz's permission-policy has additional fields over invenio-rdm's:{extras}
|
||||
I-Form's permission-policy has additional fields over invenio-rdm's:{extras}
|
||||
if this is intentional, add to ALLOWED_DIFFERENCES in test-file
|
||||
otherwise remove extraneous fields from IformRDMRecordPermissionPolicy
|
||||
"""
|
||||
@@ -47,7 +47,7 @@ def test_policies_synced() -> None:
|
||||
|
||||
if missing := set(rdm_cans) - set(iform_cans):
|
||||
msg = f"""
|
||||
invenio-rdm's permission-policy has fields unhandled by TU Graz's: {missing}
|
||||
invenio-rdm's permission-policy has fields unhandled by I-Form's: {missing}
|
||||
if this is intentional, add to ALLOWED_DIFFERENCES
|
||||
otherwise set the corresponding fields in IformRDMRecordPermissionPolicy
|
||||
"""
|
||||
@@ -65,7 +65,7 @@ def test_policies_synced() -> None:
|
||||
# we can however compare which types (classes) of Generators are used...
|
||||
if {type(gen) for gen in iform_can} != {type(gen) for gen in rdm_can}:
|
||||
msg = f"""
|
||||
permission-policy for `{can_name}` differs between TU-Graz and invenio-rdm
|
||||
permission-policy for `{can_name}` differs between I-Form and invenio-rdm
|
||||
if this is intentional, add to ALLOWED_DIFFERENCES in test-file
|
||||
otherwise fix IformRDMRecordPermissionPolicy
|
||||
"""
|
||||
@@ -81,7 +81,7 @@ def test_policies_synced() -> None:
|
||||
|
||||
if iform_label_to_action.get(label) != rdm_label_to_action.get(label):
|
||||
msg = f"""
|
||||
invenio-rdm's NEED_LABEL_TO_ACTION differs from TU Graz's in {label}
|
||||
invenio-rdm's NEED_LABEL_TO_ACTION differs from I-Form's in {label}
|
||||
if this is intentional, add to ALLOWED_DIFFERENCES in test-file
|
||||
otherwise fix IformRDMRecordPermissionPolicy.NEED_LABEL_TO_ACTION
|
||||
"""
|
||||
|
||||
79
uv.lock
generated
79
uv.lock
generated
@@ -159,36 +159,6 @@ wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/30/da/43b15f28fe5f9e027b41c539abc5469052e9d48fd75f8ff094ba2a0ae767/billiard-4.2.1-py3-none-any.whl", hash = "sha256:40b59a4ac8806ba2c2369ea98d876bc6108b051c227baffd928c644d15d8f3cb", size = 86766 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "black"
|
||||
version = "25.1.0"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
dependencies = [
|
||||
{ name = "click" },
|
||||
{ name = "mypy-extensions" },
|
||||
{ name = "packaging" },
|
||||
{ name = "pathspec" },
|
||||
{ name = "platformdirs" },
|
||||
{ name = "tomli", marker = "python_full_version < '3.11'" },
|
||||
{ name = "typing-extensions", marker = "python_full_version < '3.11'" },
|
||||
]
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/94/49/26a7b0f3f35da4b5a65f081943b7bcd22d7002f5f0fb8098ec1ff21cb6ef/black-25.1.0.tar.gz", hash = "sha256:33496d5cd1222ad73391352b4ae8da15253c5de89b93a80b3e2c8d9a19ec2666", size = 649449 }
|
||||
wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/4d/3b/4ba3f93ac8d90410423fdd31d7541ada9bcee1df32fb90d26de41ed40e1d/black-25.1.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:759e7ec1e050a15f89b770cefbf91ebee8917aac5c20483bc2d80a6c3a04df32", size = 1629419 },
|
||||
{ url = "https://files.pythonhosted.org/packages/b4/02/0bde0485146a8a5e694daed47561785e8b77a0466ccc1f3e485d5ef2925e/black-25.1.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0e519ecf93120f34243e6b0054db49c00a35f84f195d5bce7e9f5cfc578fc2da", size = 1461080 },
|
||||
{ url = "https://files.pythonhosted.org/packages/52/0e/abdf75183c830eaca7589144ff96d49bce73d7ec6ad12ef62185cc0f79a2/black-25.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:055e59b198df7ac0b7efca5ad7ff2516bca343276c466be72eb04a3bcc1f82d7", size = 1766886 },
|
||||
{ url = "https://files.pythonhosted.org/packages/dc/a6/97d8bb65b1d8a41f8a6736222ba0a334db7b7b77b8023ab4568288f23973/black-25.1.0-cp310-cp310-win_amd64.whl", hash = "sha256:db8ea9917d6f8fc62abd90d944920d95e73c83a5ee3383493e35d271aca872e9", size = 1419404 },
|
||||
{ url = "https://files.pythonhosted.org/packages/7e/4f/87f596aca05c3ce5b94b8663dbfe242a12843caaa82dd3f85f1ffdc3f177/black-25.1.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:a39337598244de4bae26475f77dda852ea00a93bd4c728e09eacd827ec929df0", size = 1614372 },
|
||||
{ url = "https://files.pythonhosted.org/packages/e7/d0/2c34c36190b741c59c901e56ab7f6e54dad8df05a6272a9747ecef7c6036/black-25.1.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:96c1c7cd856bba8e20094e36e0f948718dc688dba4a9d78c3adde52b9e6c2299", size = 1442865 },
|
||||
{ url = "https://files.pythonhosted.org/packages/21/d4/7518c72262468430ead45cf22bd86c883a6448b9eb43672765d69a8f1248/black-25.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:bce2e264d59c91e52d8000d507eb20a9aca4a778731a08cfff7e5ac4a4bb7096", size = 1749699 },
|
||||
{ url = "https://files.pythonhosted.org/packages/58/db/4f5beb989b547f79096e035c4981ceb36ac2b552d0ac5f2620e941501c99/black-25.1.0-cp311-cp311-win_amd64.whl", hash = "sha256:172b1dbff09f86ce6f4eb8edf9dede08b1fce58ba194c87d7a4f1a5aa2f5b3c2", size = 1428028 },
|
||||
{ url = "https://files.pythonhosted.org/packages/83/71/3fe4741df7adf015ad8dfa082dd36c94ca86bb21f25608eb247b4afb15b2/black-25.1.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:4b60580e829091e6f9238c848ea6750efed72140b91b048770b64e74fe04908b", size = 1650988 },
|
||||
{ url = "https://files.pythonhosted.org/packages/13/f3/89aac8a83d73937ccd39bbe8fc6ac8860c11cfa0af5b1c96d081facac844/black-25.1.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:1e2978f6df243b155ef5fa7e558a43037c3079093ed5d10fd84c43900f2d8ecc", size = 1453985 },
|
||||
{ url = "https://files.pythonhosted.org/packages/6f/22/b99efca33f1f3a1d2552c714b1e1b5ae92efac6c43e790ad539a163d1754/black-25.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:3b48735872ec535027d979e8dcb20bf4f70b5ac75a8ea99f127c106a7d7aba9f", size = 1783816 },
|
||||
{ url = "https://files.pythonhosted.org/packages/18/7e/a27c3ad3822b6f2e0e00d63d58ff6299a99a5b3aee69fa77cd4b0076b261/black-25.1.0-cp312-cp312-win_amd64.whl", hash = "sha256:ea0213189960bda9cf99be5b8c8ce66bb054af5e9e861249cd23471bd7b0b3ba", size = 1440860 },
|
||||
{ url = "https://files.pythonhosted.org/packages/09/71/54e999902aed72baf26bca0d50781b01838251a462612966e9fc4891eadd/black-25.1.0-py3-none-any.whl", hash = "sha256:95e8176dae143ba9097f351d174fdaf0ccd29efb414b362ae3fd72bf0f710717", size = 207646 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bleach"
|
||||
version = "6.2.0"
|
||||
@@ -1536,8 +1506,8 @@ dependencies = [
|
||||
tests = [
|
||||
{ name = "invenio-app" },
|
||||
{ name = "invenio-search", extra = ["opensearch2"] },
|
||||
{ name = "pytest-black-ng" },
|
||||
{ name = "pytest-invenio" },
|
||||
{ name = "pytest-ruff" },
|
||||
{ name = "ruff" },
|
||||
{ name = "sphinx" },
|
||||
]
|
||||
@@ -1553,8 +1523,8 @@ requires-dist = [
|
||||
tests = [
|
||||
{ name = "invenio-app", specifier = ">=1.5.0" },
|
||||
{ name = "invenio-search", extras = ["opensearch2"], specifier = ">=2.1.0,<3.0.0" },
|
||||
{ name = "pytest-black-ng", specifier = ">=0.4.0" },
|
||||
{ name = "pytest-invenio", specifier = ">=2.1.0,<3.0.0" },
|
||||
{ name = "pytest-ruff", specifier = ">=0.4.1" },
|
||||
{ name = "ruff", specifier = ">=0.5.3" },
|
||||
{ name = "sphinx", specifier = ">=4.5.0" },
|
||||
]
|
||||
@@ -2791,15 +2761,6 @@ wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/73/80/2708a4641f7d553a63bc934a3eb7214806b5b39d200133ca7f7afb0a53e8/msgpack-1.1.0-cp312-cp312-win_amd64.whl", hash = "sha256:115a7af8ee9e8cddc10f87636767857e7e3717b7a2e97379dc2054712693e90f", size = 75347 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "mypy-extensions"
|
||||
version = "1.1.0"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/a2/6e/371856a3fb9d31ca8dac321cda606860fa4548858c0cc45d9d1d4ca2628b/mypy_extensions-1.1.0.tar.gz", hash = "sha256:52e68efc3284861e772bbcd66823fde5ae21fd2fdb51c62a211403730b916558", size = 6343 }
|
||||
wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/79/7b/2c79738432f5c924bef5071f933bcc9efd0473bac3b4aa584a6f7c1c8df8/mypy_extensions-1.1.0-py3-none-any.whl", hash = "sha256:1be4cccdb0f2482337c4743e60421de3a356cd97508abadd57d47403e94f5505", size = 4963 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "nameparser"
|
||||
version = "1.1.3"
|
||||
@@ -3287,20 +3248,6 @@ wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/e3/b9/3541bbcb412a9fd56593005ff32183825634ef795a1c01ceb6dee86e7259/pytest-7.1.3-py3-none-any.whl", hash = "sha256:1377bda3466d70b55e3f5cecfa55bb7cfcf219c7964629b967c37cf0bda818b7", size = 298172 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "pytest-black-ng"
|
||||
version = "0.4.1"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
dependencies = [
|
||||
{ name = "black" },
|
||||
{ name = "pytest" },
|
||||
{ name = "toml" },
|
||||
]
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/a5/91/25b9d8a1ae32f481f3584338b31be6599940bc1b7ff0898b3c1c6271e509/pytest-black-ng-0.4.1.tar.gz", hash = "sha256:20c1d671b2535e5cf6f8fe03d175887a04f549cb2455264bbb81150c941bd701", size = 6399 }
|
||||
wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/52/9e/8487c641eda9b272d11fdf1cfc7f27c8496b4c3dbe97ad8349fc68c7fbfc/pytest_black_ng-0.4.1-py3-none-any.whl", hash = "sha256:d4ef8945ff410e3cb915e82420a67256aaca4e9b60cc68c7da1cd3cc85c27315", size = 4410 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "pytest-cov"
|
||||
version = "6.1.1"
|
||||
@@ -3399,6 +3346,19 @@ dependencies = [
|
||||
]
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/b3/cd/555a357a1da1c680b6417dec1aff2f5187f5559a06297b6cfab930745fc0/pytest_pydocstyle-2.4.0.tar.gz", hash = "sha256:3770689778ad8d0de8cb51264f3d9b807c11d0ecc31f95e7025426eec126c4d2", size = 5583 }
|
||||
|
||||
[[package]]
|
||||
name = "pytest-ruff"
|
||||
version = "0.4.1"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
dependencies = [
|
||||
{ name = "pytest" },
|
||||
{ name = "ruff" },
|
||||
]
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/d1/28/4d4e312a16c8969f475f6e18741bc6a2f8ee70d78e16dc3b6deba9f94e6d/pytest_ruff-0.4.1.tar.gz", hash = "sha256:2c9a30f15f384c229c881b52ec86cfaf1e79d39530dd7dd5f2d6aebe278f7eb7", size = 3919 }
|
||||
wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/0f/7a/ed1015e97fadfde96b2c439390dc5a75542a77982d775baf2ada9f536cac/pytest_ruff-0.4.1-py3-none-any.whl", hash = "sha256:69acd5b2ba68d65998c730b5b4d656788193190e45f61a53aa66ef8b390634a4", size = 4589 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "python-dateutil"
|
||||
version = "2.9.0.post0"
|
||||
@@ -4117,15 +4077,6 @@ wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/e6/34/ebdc18bae6aa14fbee1a08b63c015c72b64868ff7dae68808ab500c492e2/tinycss2-1.4.0-py3-none-any.whl", hash = "sha256:3a49cf47b7675da0b15d0c6e1df8df4ebd96e9394bb905a5775adb0d884c5289", size = 26610 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "toml"
|
||||
version = "0.10.2"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/be/ba/1f744cdc819428fc6b5084ec34d9b30660f6f9daaf70eead706e3203ec3c/toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f", size = 22253 }
|
||||
wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/44/6f/7120676b6d73228c96e17f1f794d8ab046fc910d781c8d151120c3f1569e/toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b", size = 16588 },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "tomli"
|
||||
version = "2.2.1"
|
||||
|
||||
Reference in New Issue
Block a user