想要启动的时候打开系统设置图案密码的界面,启动参数应该怎么配置

1、当前页面为系统设置里的设置图案密码的界面
image
用adb命令查出来当前的activity为
adb shell “dumpsys window windows | grep -i current”
mCurrentFocus=Window{4018797 u0 com.android.settings/com.android.settings.ConfirmLockPattern$InternalActivity}

2、我设置的启动参数为:
{
“platformName”: “android”,
“deviceName”: “127.0.0.1:7555”,
“appPackage”: “com.android.settings”,
“appActivity”: “com.android.settings.ConfirmLockPattern$InternalActivity”}

启动的时候报错了:
Encountered internal error running command: Error: Cannot start the ‘com.android.settings’ application. Visit https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/android/activity-startup.md for troubleshooting. Original error: Cannot start the ‘com.android.settings’ application. Visit https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/android/activity-startup.md for troubleshooting. Original error: Activity name ‘.com.android.settings.ConfirmLockPattern\$InternalActivity’ used to start the app doesn’t exist or cannot be launched! Make sure it exists and is a launchable activity

想请问下老师,这种想打开系统设置的启动参数该怎么设置呀

你这个报错是activity错了,不能启动导致的,检查下appPackage、appActivity对不对

有些界面是无法直接启动的 需要从其他界面跳转。你最好从首次进入的activity中转下

好的,我以为像这种也是可以直接进的,那我转一下,谢谢思寒老师~

是的,不过名称是没错的,思寒老师说可能这种界面没办法直接进~

可以被直接启动的叫launchable activity

意思是只有应用的launch activity才能被直接启动吗?

关闭