Skip to content

Commit

Permalink
feat(e2e): 支持open-type类型button的录制&回放
Browse files Browse the repository at this point in the history
re #80
  • Loading branch information
fanniehuang committed Apr 12, 2021
1 parent 3ce04cd commit 9086cdb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/wxa-cli/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@webank/wxa-cli2-apple",
"version": "1.0.41",
"version": "1.0.47",
"description": "cli for wxa development",
"main": "dist/wxa.js",
"scripts": {
Expand Down
7 changes: 5 additions & 2 deletions packages/wxa-cli/src/tester/domWalker.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,11 @@ class XMLManager {
element.attribs[`bind${$1}`] = `$$e2e_${$1}`;
}
});


}
let openType = Object.keys(attributes).some((attr)=>attr === 'open-type');
let bindtap = Object.keys(attributes).some((attr)=>attr === 'bindtap');
if (openType && !bindtap) {
element.attribs[`bindtap`] = `$$e2e_tap`;
}
// navigator标签劫持
if(element.name === 'navigator') {
Expand Down

0 comments on commit 9086cdb

Please sign in to comment.