Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validate content paths #4084

Merged
merged 53 commits into from
Mar 19, 2024
Merged

Validate content paths #4084

merged 53 commits into from
Mar 19, 2024

Conversation

dorschw
Copy link
Contributor

@dorschw dorschw commented Feb 25, 2024

@dorschw dorschw mentioned this pull request Feb 25, 2024
Copy link

Changelog(s) in markdown:

  • Added the validate-content-path pre-commit hook #4084

@coveralls
Copy link
Collaborator

coveralls commented Feb 26, 2024

Pull Request Test Coverage Report for Build 8314187683

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 186 of 186 (100.0%) changed or added relevant lines in 2 files are covered.
  • 42 unchanged lines in 13 files lost coverage.
  • Overall coverage increased (+11.6%) to 92.236%

Files with Coverage Reduction New Missed Lines %
demisto_sdk/commands/content_graph/objects/pack.py 1 99.65%
demisto_sdk/commands/content_graph/objects/base_content.py 1 99.31%
demisto_sdk/commands/pre_commit/pre_commit_command.py 1 99.67%
demisto_sdk/commands/validate/validators/DO_validators/DO104_docker_image_does_not_exist_in_yml.py 1 93.1%
demisto_sdk/commands/content_graph/objects/content_item.py 1 95.59%
demisto_sdk/commands/generate_docs/common.py 2 98.89%
demisto_sdk/commands/content_graph/neo4j_service.py 3 95.92%
demisto_sdk/commands/content_graph/interface/graph.py 4 92.51%
demisto_sdk/commands/content_graph/objects/integration_script.py 4 95.4%
demisto_sdk/commands/content_graph/objects/integration.py 4 96.83%
Totals Coverage Status
Change from base Build b8afc876-a48d-44db-b94c-c547fb2338e8: 11.6%
Covered Lines: 59482
Relevant Lines: 64489

💛 - Coveralls

@dorschw dorschw marked this pull request as ready for review March 17, 2024 08:40
@dorschw dorschw requested a review from GuyAfik as a code owner March 17, 2024 08:40
demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
@ShirleyDenkberg
Copy link
Contributor

@yuvalbenshalom @YuvHayun @GuyAfik Doc review completed.

Copy link
Contributor

@yuvalbenshalom yuvalbenshalom left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good.
see my comments.

demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved


class PathIsFolder(ExemptedPath):
message = "Path is to a folder, these are not validated."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is this case?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when the validated path is of a folder, rather than a file. Shouldn't happen really.

demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
demisto_sdk/scripts/validate_content_path.py Outdated Show resolved Hide resolved
@dorschw dorschw requested a review from yuvalbenshalom March 18, 2024 14:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants