Skip to content

Commit

Permalink
Merge pull request #496 from DataDog/s.obregoso/update_pkgs_and_top
Browse files Browse the repository at this point in the history
Fix tests and upgrade pkgs
  • Loading branch information
sobregosodd authored Dec 5, 2024
2 parents 9ea476c + 329bcc5 commit 97be47b
Show file tree
Hide file tree
Showing 8 changed files with 24,399 additions and 23,800 deletions.
14,766 changes: 7,383 additions & 7,383 deletions guarddog/analyzer/metadata/resources/top_npm_packages.json

Large diffs are not rendered by default.

31,946 changes: 15,973 additions & 15,973 deletions guarddog/analyzer/metadata/resources/top_pypi_packages.json

Large diffs are not rendered by default.

339 changes: 327 additions & 12 deletions poetry.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ guarddog = "guarddog.cli:cli"

[tool.poetry.dependencies]
python = ">=3.10,<4"
semgrep = "1.67.0"
semgrep = "^1.97.0"
requests = "^2.29.0"
python-dateutil = "^2.8.2"
click = "^8.1.3"
Expand Down
670 changes: 410 additions & 260 deletions requirements-dev.txt

Large diffs are not rendered by default.

470 changes: 302 additions & 168 deletions requirements.txt

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion tests/analyzer/metadata/test_typosquatting.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class TestTyposquatting:
("github.com/gin-golangnic/gin", "github.com/gin-gonic/gin")
]

negative_cases = ["hello-world", "foo", "bar"]
negative_cases = ["hello-world", "foo"]
same_names = ["pip", "Numpy", "openCv-python", "requests_oauthlib"]

@pytest.mark.parametrize("typo_name, real_name", pypi_typosquats)
Expand Down
4 changes: 2 additions & 2 deletions tests/reporters/test_sarif.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,5 +156,5 @@ def monkey_localscan(*args, **kwargs):
with open(os.path.join(tmp_dirname, "results.sarif"), "w") as fd:
fd.write(raw_output)
sarif_data = load_sarif_file(os.path.join(tmp_dirname, "results.sarif"))
stats = sarif_data.get_result_count_by_severity()
assert stats["warning"] == warning_count
stats_warning = sarif_data.get_report().get_issue_count_for_severity("warning")
assert stats_warning == warning_count

0 comments on commit 97be47b

Please sign in to comment.