@@ -39,7 +39,7 @@ def test_changed_id_not_resolved(
3939 self , sample_vulnerability , flipped_id_vulnerability
4040 ):
4141 """
42- Simulate a vulnerability to be still present, but it's ID having
42+ Simulate a vulnerability to be still present, but its ID having
4343 changed over time.
4444
4545 The test verifies that the vulnerability (using the original ID) is
@@ -56,6 +56,34 @@ def test_resolved(self, sample_vulnerability):
5656 matcher = VulnerabilityMatcher (current_vulnerabilities = [])
5757 assert matcher .is_resolved (vuln )
5858
59+ def test_no_resolution_same_package (self ):
60+ """
61+ Scenario: 'cryptography' has two vulnerabilities.
62+ One is resolved (removed from the current list), the other remains.
63+ """
64+ pkg_data = {"name" : "cryptography" , "version" : "46.0.6" }
65+
66+ vuln_1 = Vulnerability (
67+ package = pkg_data ,
68+ id = "GHSA-m959-cc7f-wv43" ,
69+ aliases = ["CVE-2026-34073" ],
70+ fix_versions = ["46.0.6" ],
71+ description = "Dummy description" ,
72+ )
73+
74+ vuln_2 = Vulnerability (
75+ package = pkg_data ,
76+ id = "GHSA-p423-j2cm-9vmq" ,
77+ aliases = ["CVE-2026-39892" ],
78+ fix_versions = ["46.0.7" ],
79+ description = "Dummy description" ,
80+ )
81+
82+ matcher = VulnerabilityMatcher (current_vulnerabilities = [vuln_1 , vuln_2 ])
83+
84+ assert matcher .is_resolved (vuln_1 ) is False
85+ assert matcher .is_resolved (vuln_2 ) is False
86+
5987
6088class TestDependenciesAudit :
6189 def test_no_vulnerabilities_for_previous_and_current (self ):
0 commit comments