t402600 发表于 2017-3-27 21:36:01

appium运行报错求各位大牛看看如何解决

Encountered internal error running command: Error: Error occured while starting App. Original error: com.sankuai.meituan/com.sankuai.meituan.activity.Welcome or .activity.Welcome or .com.sankuai.meituan.activity.Welcome never started
    at Object.wrappedLogger.errorAndThrow (lib/logger.js:60:13)
    at ADB.callee$0$0$ (../../../lib/tools/apk-utils.js:80:9)
    at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
    at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
    at GeneratorFunctionPrototype.prototype.(anonymous function) (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:100:21)
    at GeneratorFunctionPrototype.invoke (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:136:37)
<-- POST /wd/hub/session 500 82733 ms - 319


运行代码如下:
public class EengLu {
       
        public static void main(String[] args) throws Exception {
               
                File app=new File("/Users/dsjh/Downloads/meituan.apk");
                DesiredCapabilities caps=new DesiredCapabilities();
                caps.setCapability(MobileCapabilityType.APP, app.getAbsolutePath());
                caps.setCapability(MobileCapabilityType.DEVICE_NAME, "suibianxie");
                caps.setCapability(AndroidMobileCapabilityType.NO_SIGN, true);
                caps.setCapability(AndroidMobileCapabilityType.UNICODE_KEYBOARD, true);
                caps.setCapability(AndroidMobileCapabilityType.RESET_KEYBOARD, true);
               
                AndroidDriver<AndroidElement> driver=new AndroidDriver<>(new URL("http://127.0.0.1:4723/wd/hub"),caps);
               
        }       

}
页: [1]
查看完整版本: appium运行报错求各位大牛看看如何解决