Skip to content

Commit f10fcc4

Browse files
committed
WIP fix tests
1 parent bf5b247 commit f10fcc4

File tree

3 files changed

+26
-10
lines changed

3 files changed

+26
-10
lines changed

pyproject.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ preview = true
88
exclude = [
99
"**/__pycache__",
1010
"**/node_modules",
11+
"dogfood",
1112
"presentations",
1213
"scripts/pdoc/original.py",
1314
"scripts/pdoc/patched.py",
@@ -39,7 +40,7 @@ typeCheckingMode = "strict"
3940
useLibraryCodeForTypes = true
4041

4142
[tool.pytest.ini_options]
42-
addopts = "--cov=bioimageio --cov-report=xml --cov-append --capture=no --doctest-modules --failed-first"
43+
addopts = "--cov=bioimageio --cov-report=xml --cov-append --capture=no --doctest-modules --failed-first --ignore=dogfood"
4344

4445
[tool.ruff]
4546
line-length = 88

tests/test_bioimageio_collection.py

Lines changed: 23 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import requests
55
from pydantic import HttpUrl
66

7-
from bioimageio.spec import InvalidDescr
7+
from bioimageio.spec import InvalidDescr, ValidationContext
88
from bioimageio.spec.common import Sha256
99
from tests.utils import ParameterSet, expensive_test
1010

@@ -39,15 +39,28 @@ def yield_bioimageio_yaml_urls() -> Iterable[ParameterSet]:
3939

4040

4141
KNOWN_INVALID: Collection[str] = {
42-
"stupendous-sheep/1.2",
43-
"wild-rhino/0.1.0", # requires careamics
44-
"dazzling-spider/0.1.0", # requires careamics
45-
"humorous-fox/0.1.0", # requires careamics
42+
"affable-shark/1.1", # onnx weights expect fixed input shape
43+
"affectionate-cow/0.1.0", # custom dependencies
4644
"ambitious-sloth/1.2", # requires inferno
45+
"dazzling-spider/0.1.0", # requires careamics
4746
"dynamic-t-rex/1", # model.v0_4.ScaleLinearKwargs with axes
47+
"efficient-chipmunk/1", # needs plantseg
4848
"famous-fish/0.1.0", # list index out of range `fl[3]`
49+
"greedy-whale/1", # batch size is actually limited to 1
4950
"happy-elephant/0.1.0", # list index out of range `fl[3]`
50-
"affectionate-cow/0.1.0", # custom dependencies
51+
"humorous-crab/1", # batch size is actually limited to 1
52+
"humorous-fox/0.1.0", # requires careamics
53+
"humorous-owl/1", # error deserializing GlorotUniform
54+
"noisy-ox/1", # batch size is actually limited to 1
55+
"stupendous-sheep/1.2",
56+
"wild-rhino/0.1.0", # requires careamics
57+
"idealistic-turtle/0.1.0", # requires biapy
58+
"intelligent-lion/0.1.0", # requires biapy
59+
"merry-water-buffalo/0.1.0", # requires biapy
60+
"venomous-swan/0.1.0", # requires biapy
61+
"heroic-otter/0.1.0", # requires biapy
62+
"stupendous-sheep/1.1", # requires relativ import of attachment
63+
"commited-turkey/1.2", # error deserializng VarianceScaling
5164
}
5265

5366

@@ -63,8 +76,10 @@ def test_rdf(
6376

6477
from bioimageio.core import load_description_and_test
6578

66-
descr = load_description_and_test(descr_url, sha256=sha, stop_early=True)
79+
with ValidationContext():
80+
descr = load_description_and_test(descr_url, sha256=sha, stop_early=True)
81+
6782
assert not isinstance(descr, InvalidDescr)
6883
assert (
6984
descr.validation_summary.status == "passed"
70-
), descr.validation_summary.format()
85+
), descr.validation_summary.display()

tests/test_proc_ops.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ def test_scale_mean_variance_per_channel(tid: MemberId, axes_str: Optional[str])
268268
axes = None if axes_str is None else tuple(map(AxisId, axes_str))
269269

270270
shape = (3, 32, 46)
271-
ipt_axes = ("c", "y", "x")
271+
ipt_axes = ("channel", "y", "x")
272272
np_data = np.random.rand(*shape)
273273
ipt_data = xr.DataArray(np_data, dims=ipt_axes)
274274

0 commit comments

Comments
 (0)