#16 楼 @weamylady 你是命令行端还是哪个
#16 楼 @weamylady 你好潇洒啊,打球。。。这小日子过的
#14 楼 @weamylady 能给个下载地址么
你真的是这个问题,一模一样的?
#5 楼 @weamylady 能把脚本发来看看么
#11 楼 @chenhengjie123 是的,我把切换的注销掉还是老样子。。。停着不动
#coding=utf-8
import os
import sys
#from PIL import Image
import unittest
from appium import webdriver
from time import sleep
from appium.webdriver.common.touch_action import TouchAction
# Returns abs path relative to this file and not cwd
PATH = lambda p: os.path.abspath(
os.path.join(os.path.dirname(__file__), p)
)
desired_caps = {}
#desired_caps['automationName'] = 'Selendroid'
desired_caps['platformName'] = 'Android'
desired_caps['platformVersion'] = '4.4'
desired_caps['deviceName'] = '192.168.56.101:5555'
desired_caps['appPackage'] = 'com.jiudao.ccare'
desired_caps['appActivity'] = '.MainActivity'
desired_caps['autoWebview'] = 'true'
desired_caps["unicodeKeyboard"] = "True"
desired_caps["resetKeyboard"] = "True"
desired_caps['autoWebview'] = 'true'
dr = webdriver.Remote('http://192.168.10.65:4723/wd/hub', desired_caps)
dr.implicitly_wait(10)
#a=dr.contexts
#print (a)
#time.sleep(3)
#dr.switch_to.context("WEBVIEW_com.jiudao.ccare")
username=dr.find_element_by_id("username")
username.clear()
username.send_keys("admin@WOT")
password=dr.find_element_by_id("username")
password.clear()
password.send_keys("1")
dr.close_app()
dr.quit()
#3 楼 @weamylady 你好,你的 hybrid app 实现了么?求 qq,我想咨询咨询
#6 楼 @chenhengjie123
同样的脚本我又运行了,今天刚刚重装好电脑。。。
同样的脚本,模拟器是 4.4 三星 S4,然后运行了出现下图
还有我想问下设置 --chromedriver-port 的参数,启动的时候 appium --chromedriver-port <端口号>这样么?
#7 楼 @yuwuhen333 看到你代码了
#1 楼 @cy_suncheng info: [debug] No old chromedrivers seemed to exist?这句话?请问你 qq 多少,qq 能不能细聊
走
#19 楼 @yuwuhen333 qq 多少来着?
你 webview 搞定没
#3 楼 @lihuazhang 这周周末补充
老王加个好友
#3 楼 @chenhengjie123 - -!好吧,下次注意,主要难得装起来。如果再卸掉,可能又装不起来了。我搞这个东西,搞了蛮久的。仅仅就是推荐一个 nodejs 的版本
#1 楼 @chenhengjie123 ok 了,就是官网。。
#18 楼 @yuwuhen333 成功了不就行了,成功就不用跟我汇报了。。
#10 楼 @xdlhy
http://m.blog.csdn.net/blog/yunbin_7/40083983
这个帖子的这个代码在 python3.x 里不能运行成功的。因为我是从 2.7 转到 3.x 的,所以尝试过,会报错。所以你这个网址的解决方案估计只能是 2.x 版本的 python
import sys
reload(sys)
sys.setdefaultencoding('utf-8')