Report receiver: say whether a report came from MiniServer or CoreDesktop
shellcheck / shellcheck (push) Failing after 22s
shellcheck / shellcheck (push) Failing after 22s
Every issue said it came from CoreDesktop. MiniServer's reports send a version starting with "MiniServer ", so sender() reads the product from that, and the issue's version row and footer now name it, with the prefix taken off the version. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -213,6 +213,22 @@ class PartsTest(unittest.TestCase):
|
||||
self.assertIn("`````\n````\nlog\n`````", body)
|
||||
self.assertEqual(receiver.issue_title(details), "Update failed in a b (v _ 1)")
|
||||
|
||||
def test_the_body_names_the_product_that_sent_the_report(self):
|
||||
details = {"kind": "update", "version": "MiniServer 2026.11.19 (1c5b28b)", "failed": "x",
|
||||
"kernel": "", "siblings": ""}
|
||||
self.assertEqual(receiver.sender(details), ("MiniServer", "2026.11.19 (1c5b28b)"))
|
||||
body = receiver.issue_body("CD-TEST23", details, "log\n", "now")
|
||||
self.assertIn("| MiniServer | `2026.11.19 (1c5b28b)` |", body)
|
||||
self.assertIn("from a MiniServer machine.", body)
|
||||
self.assertNotIn("CoreDesktop", body)
|
||||
|
||||
details["version"] = "2026.11.19 (d456e31)"
|
||||
self.assertEqual(receiver.sender(details), ("CoreDesktop", "2026.11.19 (d456e31)"))
|
||||
body = receiver.issue_body("CD-TEST23", details, "log\n", "now")
|
||||
self.assertIn("| CoreDesktop | `2026.11.19 (d456e31)` |", body)
|
||||
self.assertIn("from a CoreDesktop machine.", body)
|
||||
self.assertNotIn("MiniServer", body)
|
||||
|
||||
def test_ids_are_easy_to_read_out(self):
|
||||
for _ in range(100):
|
||||
report_id = receiver.new_id()
|
||||
|
||||
Reference in New Issue
Block a user