mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-07-24 13:01:56 +00:00
feat(jira): add color for manual status (#8642)
This commit is contained in:
@@ -8,6 +8,7 @@ All notable changes to the **Prowler SDK** are documented in this file.
|
||||
- Add more fields for the Jira ticket and handle custom fields errors [(#8601)](https://github.com/prowler-cloud/prowler/pull/8601)
|
||||
- Get Jira projects from test_connection [(#8634)](https://github.com/prowler-cloud/prowler/pull/8634)
|
||||
- `AdditionalUrls` field in CheckMetadata [(#8590)](https://github.com/prowler-cloud/prowler/pull/8590)
|
||||
- Support color for MANUAL finidngs in Jira tickets [(#8642)](https://github.com/prowler-cloud/prowler/pull/8642)
|
||||
|
||||
### Changed
|
||||
|
||||
|
||||
@@ -789,6 +789,9 @@ class Jira:
|
||||
return "#FF0000"
|
||||
if status == "MUTED":
|
||||
return "#FFA500"
|
||||
if status == "MANUAL":
|
||||
return "#FFFF00"
|
||||
return "#000000"
|
||||
|
||||
@staticmethod
|
||||
def get_severity_color(severity: str) -> str:
|
||||
|
||||
@@ -976,7 +976,12 @@ class TestJiraIntegration:
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"status, expected_color",
|
||||
[("FAIL", "#FF0000"), ("PASS", "#008000"), ("MUTED", "#FFA500")],
|
||||
[
|
||||
("FAIL", "#FF0000"),
|
||||
("PASS", "#008000"),
|
||||
("MUTED", "#FFA500"),
|
||||
("MANUAL", "#FFFF00"),
|
||||
],
|
||||
)
|
||||
def test_get_color_from_status(self, status, expected_color):
|
||||
"""Test that get_color_from_status returns the correct color for a status."""
|
||||
|
||||
Reference in New Issue
Block a user