Esegui test di strumentazione da APK esistenti,Esegui test di strumentazione da APK esistenti,Esegui test di strumentazione da APK esistenti

Queste istruzioni presuppongono che tu abbia il pacchetto Trade Federation disponibile localmente; in caso contrario, seguire le istruzioni per il download per ottenerlo.

Utilizzare quindi il seguente comando per installare l'APK dei test di strumentazione, eseguire i test e visualizzare i test in esecuzione:

./tradefed.sh run instrumentations --apk-path <path of your apk>

Con output simile a:

07-17 10:55:32 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testOfArgb
07-17 10:55:33 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testIsRunning
07-17 10:55:34 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testGetCurrentPlayTime
07-17 10:55:35 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testStartDelay
07-17 10:55:35 I/InvocationToJUnitResultForwarder: Run ended in 2m 20s

È facoltativamente possibile specificare --serial <device serial number> da eseguire su un determinato dispositivo. Il numero di serie del tuo dispositivo può essere ottenuto utilizzando adb devices .

Vedere la sezione Test tramite Tradefed per maggiori dettagli sulle esecuzioni Tradefed.

,

Queste istruzioni presuppongono che tu abbia il pacchetto Trade Federation disponibile localmente; in caso contrario, seguire le istruzioni per il download per ottenerlo.

Utilizzare quindi il seguente comando per installare l'APK dei test di strumentazione, eseguire i test e visualizzare i test in esecuzione:

./tradefed.sh run instrumentations --apk-path <path of your apk>

Con output simile a:

07-17 10:55:32 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testOfArgb
07-17 10:55:33 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testIsRunning
07-17 10:55:34 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testGetCurrentPlayTime
07-17 10:55:35 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testStartDelay
07-17 10:55:35 I/InvocationToJUnitResultForwarder: Run ended in 2m 20s

È facoltativamente possibile specificare --serial <device serial number> da eseguire su un determinato dispositivo. Il numero di serie del tuo dispositivo può essere ottenuto utilizzando adb devices .

Vedere la sezione Test tramite Tradefed per maggiori dettagli sulle esecuzioni Tradefed.

,

Queste istruzioni presuppongono che tu abbia il pacchetto Trade Federation disponibile localmente; in caso contrario, seguire le istruzioni per il download per ottenerlo.

Utilizzare quindi il seguente comando per installare l'APK dei test di strumentazione, eseguire i test e visualizzare i test in esecuzione:

./tradefed.sh run instrumentations --apk-path <path of your apk>

Con output simile a:

07-17 10:55:32 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testOfArgb
07-17 10:55:33 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testIsRunning
07-17 10:55:34 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testGetCurrentPlayTime
07-17 10:55:35 D/InvocationToJUnitResultForwarder: Starting test: android.animation.cts.ValueAnimatorTest#testStartDelay
07-17 10:55:35 I/InvocationToJUnitResultForwarder: Run ended in 2m 20s

È facoltativamente possibile specificare --serial <device serial number> da eseguire su un determinato dispositivo. Il numero di serie del tuo dispositivo può essere ottenuto utilizzando adb devices .

Vedere la sezione Test tramite Tradefed per maggiori dettagli sulle esecuzioni Tradefed.