grafana formatter: smaller titles

This commit is contained in:
Guilhem Saurel 2021-09-13 17:03:57 +02:00
parent 6c5b3e1358
commit 624a1b2c08
2 changed files with 2 additions and 2 deletions

View file

@ -5,7 +5,7 @@ def grafana(data, headers):
"""Pretty-print a grafana notification."""
text = ""
if "title" in data:
text = "### " + data["title"] + "\n"
text = "#### " + data["title"] + "\n"
if "message" in data:
text = text + data["message"] + "\n\n"
if "evalMatches" in data:

View file

@ -42,5 +42,5 @@ class GrafanaFormatterTest(unittest.IsolatedAsyncioTestCase):
self.assertEqual(message.sender, FULL_ID)
self.assertEqual(
message.body,
"### [Alerting] Panel Title alert\nNotification Message\n\n* Count: 1\n",
"#### [Alerting] Panel Title alert\nNotification Message\n\n* Count: 1\n",
)