Skip to content

Commit 44daf6c

Browse files
committed
Extend and fix test coverage
1 parent 99bb137 commit 44daf6c

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

tests/resolution/evaluation/test_evaluate_core_version.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
(f"{datetime.now().year - 2}.1", True), # 2 years old, unsupported
2424
(f"{datetime.now().year - 3}.1", True), # 3 years old, unsupported
2525
("2021.6.0", True), # Very old version, unsupported
26+
("0.116.4", True), # Old version scheme, should be unsupported
27+
("0.118.1", True), # Old version scheme, should be unsupported
2628
("landingpage", False), # Landingpage version, should be supported
2729
(None, False), # No current version info, check skipped
2830
],
@@ -72,7 +74,8 @@ async def test_core_version_evaluation_no_latest(coresys: CoreSys):
7274
):
7375
assert evaluation.reason not in coresys.resolution.unsupported
7476
await evaluation()
75-
assert evaluation.reason not in coresys.resolution.unsupported
77+
# Without latest version info, old versions should be marked as unsupported
78+
assert evaluation.reason in coresys.resolution.unsupported
7679

7780

7881
async def test_core_version_invalid_format(coresys: CoreSys):
@@ -94,8 +97,8 @@ async def test_core_version_invalid_format(coresys: CoreSys):
9497
):
9598
assert evaluation.reason not in coresys.resolution.unsupported
9699
await evaluation()
97-
# Should handle gracefully and not mark as unsupported
98-
assert evaluation.reason not in coresys.resolution.unsupported
100+
# Invalid/non-parseable versions should be marked as unsupported
101+
assert evaluation.reason in coresys.resolution.unsupported
99102

100103

101104
async def test_core_version_landingpage(coresys: CoreSys):

0 commit comments

Comments
 (0)