Android checklist:
JAVA version is 1.8.0_151
JAVA_HOME is set to /usr/lib/jvm/java-8-oracle
ANDROID_HOME is set to /opt/android-sdk-linux
Platforms is set to /opt/android-sdk-linux/platforms/android-26
ADB tool is set to /opt/android-sdk-linux/platform-tools/adb
gradle is installed, version: 3.5
macaca server Log:
cmd@TR:~$ macaca server --verbose
index.js:18:12 [master] pid:25392 webdriver server start with config:
{ port: 3456,
verbose: true,
always: true,
ip: '192.168.66.113',
host: 'TR',
loaded_time: '2018-01-04 15:19:49' }
middlewares.js:17:10 [master] pid:25392 base middlewares attached
router.js:133:10 [master] pid:25392 router set
webdriver sdk launched
responseHandler.js:11:12 [master] pid:25392 Recieve HTTP Request from Client[2018-01-04 15:20:10]: method: POST url: /wd/hub/session, jsonBody: {"desiredCapabilities":{"platformName":"Desktop","browserName":"Electron","url":"https://www.baidu.com"}}
session.js:47:10 [master] pid:25392 Creating session, sessionId: 15883f93-9eca-40fc-b07c-f0efbd95ecc1.
responseHandler.js:49:14 [master] pid:25392 Send HTTP Respone to Client[2018-01-04 15:20:13]: {"sessionId":"15883f93-9eca-40fc-b07c-f0efbd95ecc1","status":0,"value":"{\"platformName\":\"Desktop\",\"browserName\":\"Electron\",\"url\":\"https://www.baidu.com\"}"}
responseHandler.js:11:12 [master] pid:25392 Recieve HTTP Request from Client[2018-01-04 15:20:13]: method: POST url: /wd/hub/session/15883f93-9eca-40fc-b07c-f0efbd95ecc1/url, jsonBody: {"url":"https://www.baidu.com"}
responseHandler.js:49:14 [master] pid:25392 Send HTTP Respone to Client[2018-01-04 15:20:13]: {"sessionId":"15883f93-9eca-40fc-b07c-f0efbd95ecc1","status":0,"value":null}
A Parser-blocking, cross site (i.e. different eTLD+1) script, http://s1.bdstatic.com/r/www/cache/static/global/js/all_async_search_f5b321b.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
A Parser-blocking, cross site (i.e. different eTLD+1) script, http://s1.bdstatic.com/r/www/cache/static/global/js/all_async_search_f5b321b.js, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.
responseHandler.js:11:12 [master] pid:25392 Recieve HTTP Request from Client[2018-01-04 15:20:19]: method: GET url: /wd/hub/session/15883f93-9eca-40fc-b07c-f0efbd95ecc1/source, jsonBody: {}
responseHandler.js:49:14 [master] pid:25392 Send HTTP Respone to Client[2018-01-04 15:20:19]: {"sessionId":"15883f93-9eca-40fc-b07c-f0efbd95ecc1","status":0,"value":"\"
cmd@TR:~$ macaca doctor macaca-doctor version: 2.0.4
Node.js checklist: node env: /opt/nodejs/bin/node node version: v6.10.3
Android checklist: JAVA version is
1.8.0_151
JAVA_HOME is set to/usr/lib/jvm/java-8-oracle
ANDROID_HOME is set to/opt/android-sdk-linux
Platforms is set to/opt/android-sdk-linux/platforms/android-26
ADB tool is set to/opt/android-sdk-linux/platform-tools/adb
gradle is installed, version: 3.5Installed driver list: android: 2.0.45 chrome: 1.0.7 electron: 1.1.19
cmd@TR:~$ nosmoke -v 1.0.1
cmd@TR:~$ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 16.04.3 LTS Release: 16.04 Codename: xenial
H5Test.yml内容
1. Initialization option
desiredCapabilities:
Web Configuration
platformName: 'Desktop' browserName: 'Electron' url: 'http://m.aicai.com/m/register.do?agentId=14759&vt=5'
2. Crawling option
Web Configuration
crawlingConfig: platform: 'pc-web' targetElements: CommonRegist: searchValue : '常规注册' loginAccount: searchValue : 'jq_account' actionValue : 'postsay123' loginPassword: searchValue : 'jq_comm_pass' actionValue : '$%^&*213' CellPhoneNumber: searchValue : 'jq_mobile' actionValue : '13751077575' loginButton: searchValue : 'common_registe' alertConfirm: searchValue : '该手机号已在本站注册过了,请更换手机号再试,多谢合作!' clickTypes:
alertConfirm:
searchValue : 'yes'
macaca server Log cmd@TR:~$ macaca server --verbose
nosmoke Log cmd@TR:~/scripts/NoSmoke/web$ nosmoke -c H5Test.yml --verbose
然后就是如此一直报该句 reporter generated: /home/cmd/scripts/NoSmoke/web/reports/2018-0-4-15:15:42-report.html 现象是并没优先 找到 常规注册 然后点击 就一直循环。 这是一个问题 。
另这份也无法跑通,这份的现象就是访问到百度 接下来 并不执行后续配置的遍历内容。
webTest.yml内容
1. Initialization option
desiredCapabilities:
Electron Configuration
platformName: 'Desktop' browserName: 'Electron' url: 'https://www.baidu.com'
2. Crawling option
crawlingConfig: platform: 'pc-web' targetElements: SearchConetent: actionType: 2 searchValue : 'kw' actionValue : '中文+Test+Nosmoke' Search: actionType: 1 searchValue : 'su' clickTypes:
macaca server Log: cmd@TR:~$ macaca server --verbose
nosmoke Log: cmd@TR:~/scripts/NoSmoke/web$ nosmoke -c webTest.yml --verbose