Add final runtime and disk usage summary to mail reports

This commit is contained in:
admin committed 2026-09-25 13:35:01 +02:00
1 parent a5a7e38853
commit be48ee85ef
13 files changed
+142 -9

No files matched your search

+5
View File
@@ -135,6 +135,11 @@ MAIL_SENDMAIL_BIN="{self.sendmail}"
mail = BytesParser(policy=policy.default).parsebytes((self.base/'mail.eml').read_bytes())
self.assertIn('[app-restore-test] SUCCESS gemini.jr-it-services.de',str(mail['Subject']))
self.assertIn('Bereinigung: OK',mail.get_content())
summary=mail.get_content().split('Laufzeit und Speicher am Ende',1)[1]
self.assertIn('Verarbeitung:',summary)
self.assertIn('Restore-Test:',summary)
self.assertIn('Frei auf Datenträger Arbeitsbereich:',summary)
self.assertRegex(summary,r'Restore-Test: (?!nicht verfügbar)')
self.assertNotIn('expected data',mail.get_content())
self.assertEqual((self.root/'last-success.json').stat().st_mode & 0o777,0o600)
self.execute('--cleanup')