Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Туториал. Урок 4 "Выполнение adb-команд". Команда "adbServer.performShell("pm list packages")" падает "with timeout exception" #582

Open
Paiper147 opened this issue Sep 26, 2023 · 0 comments
Labels
bug Something isn't working documentation Improvements or additions to documentation

Comments

@Paiper147
Copy link

Describe the bug
https://kasperskylab.github.io/Kaspresso/ru/Tutorial/Working_with_adb/#adb_1
Урок 4 "Выполнение adb-команд"

В уроке приведена одна из команд
val packages = adbServer.performShell("pm list packages")
Assert.assertTrue(device.targetContext.packageName in packages.first())

Однако при попытке её выполнить, в логах теста выводится:
"com.kaspersky.kaspresso.internal.exceptions.AdbServerException:
AdbServer. The command=pm list packages was performed with timeout exception."
image

В консоле выводится:
INFO 26/09/2023 11:59:52.833 desktop=Desktop-21720 device=emulator-5554 message: The received command to execute: AdbCommand(body=shell pm list packages)
INFO 26/09/2023 12:01:52.843 desktop=Desktop-21720 device=emulator-5554 message: The executed command: AdbCommand(body=shell pm list packages). The result: CommandResult(status=TIMEOUT, description=Command execution timeout (120 sec) overhead, serviceInfo=The command was executed on desktop=Desktop-21720)
image

Код, указанный выше, был запущен из ветки "TECH-tutorial-results", класс AdbTest.kt.
Также есть класс DeviceServerSampleTest.kt , в котором приведён аналогичный тест
val command = "pm list packages ${device.targetContext.packageName}"
val result = adbServer.performShell(command)
assertTrue("package:${device.targetContext.packageName}" in result.first())
Данный код выполняется БЕЗ ошибок

image

@Paiper147 Paiper147 added the bug Something isn't working label Sep 26, 2023
@AzamatCherchesov AzamatCherchesov added the documentation Improvements or additions to documentation label Oct 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants