Skip to content

Commit

Permalink
get description for non mappable capabilities that have pages created…
Browse files Browse the repository at this point in the history
… for them
  • Loading branch information
Eva committed Feb 26, 2024
1 parent 18e6102 commit 156be25
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/mappings_explorer/site_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,15 @@ def parse_capability_groups(
}
)
if project.id == "nist" or project.id == "cve":
for capability in project.capabilities:
# if the project has non mappable comments and we are therefore building the
# capability page even though it is non_mappable, get non_mappable capabilities'
# descriptions as well
capabilities_to_get_description = (

Check warning on line 416 in src/mappings_explorer/site_builder.py

View check run for this annotation

Codecov / codecov/patch

src/mappings_explorer/site_builder.py#L416

Added line #L416 was not covered by tests
project.capabilities
if not project.has_non_mappable_comments
else project.capabilities.extend(project.non_mappables)
)
for capability in capabilities_to_get_description:

Check warning on line 421 in src/mappings_explorer/site_builder.py

View check run for this annotation

Codecov / codecov/patch

src/mappings_explorer/site_builder.py#L421

Added line #L421 was not covered by tests
get_description_for_capability(capability, project, project_version)
if project.id == "aws" or project.id == "gcp" or project.id == "azure":
get_security_stack_descriptions(project=project)
Expand Down

0 comments on commit 156be25

Please sign in to comment.