@@ -41,7 +41,7 @@ def test_parse_file_with_one_vuln_and_compliance(self):
4141 # Verify compliance finding has image metadata in impact field
4242 self .assertIn ("Image ID:" , finding .impact )
4343 self .assertIn ("Distribution:" , finding .impact )
44- self .assertTrue ("\n " in finding .impact )
44+ self .assertIn ("\n " , finding .impact )
4545 else :
4646 # Verify vulnerability finding exists and has correct properties
4747 self .assertIsNotNone (finding )
@@ -52,7 +52,7 @@ def test_parse_file_with_one_vuln_and_compliance(self):
5252 self .assertIn ("Image ID:" , finding .impact )
5353 self .assertIn ("Distribution:" , finding .impact )
5454 self .assertIn ("Debian GNU/Linux 9" , finding .impact )
55- self .assertTrue ("\n " in finding .impact )
55+ self .assertIn ("\n " , finding .impact )
5656
5757 def test_parse_csv_with_timestamps_and_metadata (self ):
5858 testfile = (
@@ -69,8 +69,8 @@ def test_parse_csv_with_timestamps_and_metadata(self):
6969 # Verify timestamp parsing (Item 4)
7070 self .assertIsNotNone (finding .date )
7171 # Should use Published date (2020-09-04) or Discovered date (2020-09-29)
72- self .assertTrue (finding .date .year == 2020 )
73- self .assertTrue (finding .date .month in {9 , 1 , 11 , 12 }) # Various months from the test data
72+ self .assertEqual (finding .date .year , 2020 )
73+ self .assertIn (finding .date .month , {9 , 1 , 11 , 12 }) # Various months from the test data
7474
7575 # Verify metadata in impact field (Item 3) - now separated by newlines
7676 self .assertIn ("Registry:" , finding .impact )
0 commit comments