Integration tests don't check screenshots

Aperta
#2,918 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 5 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
55/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
csharp, unity
Ambito
testing

Direzione di ricerca

Start with the integration tests for messages and exceptions and inspect how IntegrationTester handles quitting after capture. Check how app-runner uses sentry-api-client to fetch event attachments, since the issue says it lacks a function for reading them. Done when tests wait for screenshots where applicable and assert that screenshot.jpg is nonempty, skipping batch mode and WebGL.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Tests Unity

The integration tests don't check screenshots. They fetch the event the test app printed and check its fields, but not its screenshot.jpg, so a broken or empty screenshot goes unnoticed. This let the Metal readback error fixed in #2917 pass CI: the iOS simulator and macOS runs logged it on every capture.

The screenshots are empty in CI on every platform anyway. The test app calls Application.Quit in the frame it captures in, so the end-of-frame screenshot never gets taken and the SDK sends a 0-byte screenshot.jpg ("Screenshot was not taken in time").

What we could do:

  • Let IntegrationTester wait for the screenshot before quitting in the message and exception tests.
  • Assert that the event's screenshot.jpg isn't empty, skipped where no screenshot is taken (batch mode, WebGL). Reading attachments needs a function in app-runner's sentry-api-client, which has none.
Lingua principale
C#
Stelle
295
Fork
63
Merge medio
4g 10h
PR unite (30g)
29

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di getsentry/sentry-unity

Tutte le issue di getsentry/sentry-unity

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.