1616 # Product,
1717 Test ,
1818)
19- from dojo .tools .reversinglabs_spectraassure .parser import (
20- ReversinglabsSpectraassureParser ,
21- )
2219from unittests .dojo_test_case import (
2320 DojoTestCase ,
2421 get_unit_tests_scans_path ,
2522)
2623
24+ from dojo .tools .reversinglabs_spectraassure .parser import (
25+ ReversinglabsSpectraassureParser ,
26+ )
27+
2728_WHERE = "reversinglabs_spectraassure"
2829
2930_FILES = [
3334]
3435
3536
36- class TestReversingLabsSpectraAssureParser (DojoTestCase ): # type: ignore
37+ # mypy gives: error: Class cannot subclass "DojoTestCase" (has type "Any") [misc]
38+ class TestReversingLabsSpectraAssureParser (DojoTestCase ): # type: ignore[misc]
3739 def common_checks (self , finding : Finding ) -> None :
3840 self .assertLessEqual (len (finding .title ), 250 )
3941 self .assertIn (finding .severity , Finding .SEVERITIES )
@@ -56,7 +58,7 @@ def test_parse_file_with_no_vuln(self) -> None:
5658
5759 def test_parse_file_with_one_vuln (self ) -> None :
5860 with (get_unit_tests_scans_path (_WHERE ) / "putty_win_x64-0.80.exe-report.rl.json" ).open (
59- encoding = "utf-8"
61+ encoding = "utf-8" ,
6062 ) as testfile :
6163 parser = ReversinglabsSpectraassureParser ()
6264 findings = parser .get_findings (
@@ -70,7 +72,7 @@ def test_parse_file_with_one_vuln(self) -> None:
7072
7173 def test_parse_file_with_many_vulns (self ) -> None :
7274 with (get_unit_tests_scans_path (_WHERE ) / "HxDSetup_2.5.0.exe-report.rl.json" ).open (
73- encoding = "utf-8"
75+ encoding = "utf-8" ,
7476 ) as testfile :
7577 parser = ReversinglabsSpectraassureParser ()
7678 findings = parser .get_findings (
0 commit comments