Skip to content

Commit c5f0cb4

Browse files
ruff
1 parent d9be4d2 commit c5f0cb4

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

unittests/tools/test_snyk_issue_api_parser_with_json.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
1-
from pathlib import Path
21

3-
from django.test import TestCase
42

53
from dojo.models import Test
64
from dojo.tools.snyk_issue_api.parser import SnykIssueApiParser
75
from unittests.dojo_test_case import DojoTestCase, get_unit_tests_scans_path
86

7+
98
class TestSnykIssueApiParserWithJson(DojoTestCase):
109
def parse_json(self, filename):
1110
testfile = (get_unit_tests_scans_path("snyk_issue_api") / filename).open(encoding="utf-8")
1211
parser = SnykIssueApiParser()
1312
return parser.get_findings(testfile, Test())
1413

15-
1614
def test_parse_sca_single_finding(self):
1715
findings = self.parse_json("snyk_sca_scan_api_single_vuln.json")
1816
self.assertEqual(1, len(findings))
@@ -496,4 +494,4 @@ def test_deduplication_fields_match_other_snyk_scans_for_code(self):
496494
# currently deduplication is only done via 2 fields 'vuln_id_from_tool' and 'file_path'
497495
# !!! sarif value is something like 'python/CodeInjection', cannot be matched
498496
self.assertEqual("9a29d87f-aa94-47eb-b46f-375b293a8631", finding.vuln_id_from_tool)
499-
self.assertEqual("path/path/file.abc", finding.file_path)
497+
self.assertEqual("path/path/file.abc", finding.file_path)

0 commit comments

Comments
 (0)