Successfully modified file: /home/Messier82/projects/service-book/app/src/androidTest/java/com/yorvana/testsupport/DemoMode.kt (1 replacements). Here is the updated code: ... fun exit() { runShell("am broadcast -a com.android.systemui.demo -e command exit") } fun ensureOutputDirectory() { runShell("mkdir -p ${ScreenshotConstants.DEVICE_SCREENSHOT_DIR}") } fun runShell(command: String): String { val automation = InstrumentationRegistry.getInstrumentation().uiAutomation val descriptor = automation.executeShellCommand(command) ...