android / android/android-test

Synchronization capabilities: allow to wait for a View or Fragment to exist

Offen
#2,147 1 Kommentar 1 Reaktion 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
Java
Sterne
1.2k
Forks
342
Ø Merge
11 Std. 29 Min.
Gemergte PRs (30 T.)
2

Beschreibung

Espresso should allow to wait for a View or Fragment to appear (with a timeout).

The "Idling system" makes a lot of assumptions about the implementation details of the app, and makes difficult to test the **UI** of an asynchronous app without having to instrument async operations in the app, which is simply not realistic for modern apps where everything is async (or should be anyway). This makes the success of the test depend on instrumentation code spread around the codebase instead of just the actual behaviour of the app and the code of the test itself.

In general, testing the UI should not _require_ knowledge about the implementation details of the backend.

It would help if the test API allowed to wait for a View or Fragment to appear, with a timeout or other failure conditions.

Many thanks

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Beginne mit der Prüfung von Espressos Idling-System und des in diesem Issue beschriebenen Synchronisierungsverhaltens. Lege fest, wie die Test-API auf eine View oder ein Fragment warten soll, einschließlich Timeout- und Fehlerbedingungen; als abgeschlossen gilt die Aufgabe, wenn ein abgestimmtes Design und die entsprechende Abdeckung für das asynchrone Erscheinen der UI vorhanden sind.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
java
Bereich
testing
Issue-Typ
Feature
Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Aktivitätsstatus
Veraltet
Klarheit
Muss geklärt werden
Anfängerfreundlichkeit
20/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.