fix: align proof, treatment, metrics and site videos with PDF
All checks were successful
Build and deploy / Validate source (push) Successful in 11s
Build and deploy / Integration suite on a real stack (push) Successful in 5m44s
Build and deploy / Secret scan and release gate (push) Successful in 6s
Build and deploy / Publish images (push) Successful in 1m22s

This commit is contained in:
Cauê Faleiros
2026-11-06 15:27:48 -03:00
parent f4cd1842ca
commit a712c69aca
30 changed files with 631 additions and 110 deletions

View File

@@ -17,7 +17,7 @@ class PrumoReportTests(unittest.TestCase):
}
started = datetime(2026, 11, 5, 14, 0, tzinfo=timezone.utc)
return {'snapshot': {'items': [item]}, 'print_files': [{
'item_index': 0, 'created_at': started, 'finished_at': started + timedelta(seconds=41),
'item_index': 0, 'status': 'ready', 'created_at': started, 'finished_at': started + timedelta(seconds=41),
'detail': {'format': 'png', 'dpi': 300, 'parts': [
{'from_cm': '0', 'to_cm': '15'}, {'from_cm': '15', 'to_cm': '16'}]},
}]}
@@ -27,7 +27,7 @@ class PrumoReportTests(unittest.TestCase):
text = '\n'.join(lines)
self.assertIn('Chegou CDR, era PDF por dentro', text)
self.assertIn('PDF → PNG 300 DPI', text)
self.assertIn('Veio em 96 DPI, ampliado para 300', text)
self.assertIn('Resolução detectada: 96 DPI', text)
self.assertIn('3 pontos < 2 mm — cliente aceitou', text)
self.assertIn('2 artes, 1 girada', text)
self.assertIn('Menor traço 6 px → C2', text)
@@ -42,6 +42,17 @@ class PrumoReportTests(unittest.TestCase):
self.assertIn('3 pontinhos', text)
self.assertIn('C2', text)
self.assertIn('C1', text)
self.assertIn('será preparado', text)
self.assertNotIn('foi ampliada', text)
def test_unfinished_job_does_not_claim_a_conversion_or_background_check(self):
order = self.order()
order['print_files'] = [{'item_index': 0, 'status': 'manual', 'detail': {}}]
lines = report(order, {'u1': {'name': 'arte.pdf', 'original_name': 'arte.cdr'}})
text = '\n'.join(lines)
self.assertIn('Arquivo exige preparo manual', text)
self.assertNotIn('PDF → PNG', text)
self.assertNotIn('Fundo transparente', text)
if __name__ == '__main__':