Showing
6 changed files
with
112 additions
and
16 deletions
@@ -26,6 +26,9 @@ module.exports = { | @@ -26,6 +26,9 @@ module.exports = { | ||
26 | {op: 'YB_PAGE_EXIT', name: '首页载出', equals: { PAGE_ID: 'sy' }}, | 26 | {op: 'YB_PAGE_EXIT', name: '首页载出', equals: { PAGE_ID: 'sy' }}, |
27 | {op: 'YB_PAGE_ENTER', name: '首页载入', equals: { PAGE_ID: 'sy' }}, | 27 | {op: 'YB_PAGE_ENTER', name: '首页载入', equals: { PAGE_ID: 'sy' }}, |
28 | {op: 'YB_PAGE_EXIT', name: '首页载出', equals: { PAGE_ID: 'sy' }}, | 28 | {op: 'YB_PAGE_EXIT', name: '首页载出', equals: { PAGE_ID: 'sy' }}, |
29 | + {op: 'YB_PAGE_ENTER', name: '首页载入', equals: { PAGE_ID: 'sy' }}, | ||
30 | + {op: 'YB_PAGE_EXIT', name: '首页载出', equals: { PAGE_ID: 'sy' }}, | ||
31 | + {op: 'YB_PAGE_ENTER', name: '首页载入', equals: { PAGE_ID: 'sy' }}, | ||
29 | 32 | ||
30 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光1469', types:{DATA: Array}, equals: { SUB_C_ID:'1469'}}, | 33 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光1469', types:{DATA: Array}, equals: { SUB_C_ID:'1469'}}, |
31 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光2073', types:{DATA: Array}, equals: { SUB_C_ID:'2073'}}, | 34 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光2073', types:{DATA: Array}, equals: { SUB_C_ID:'2073'}}, |
@@ -33,14 +36,19 @@ module.exports = { | @@ -33,14 +36,19 @@ module.exports = { | ||
33 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光1', types:{DATA: Array}, equals: { SUB_C_ID:'1'}}, | 36 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光1', types:{DATA: Array}, equals: { SUB_C_ID:'1'}}, |
34 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光2', types:{DATA: Array}, equals: { SUB_C_ID:'2'}}, | 37 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光2', types:{DATA: Array}, equals: { SUB_C_ID:'2'}}, |
35 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光3', types:{DATA: Array}, equals: { SUB_C_ID:'3'}}, | 38 | {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光3', types:{DATA: Array}, equals: { SUB_C_ID:'3'}}, |
39 | + {op: 'YB_SHOW_MAIN_RECOMMEND', name: '首页猜你喜欢接口曝光有食', types:{DATA: Array}, equals: { SUB_C_ID:'2077'}}, | ||
40 | + {op: 'YB_SHOW_MAIN_RECOMMEND', name: '默认的首页猜你喜欢接口曝光'}, | ||
36 | 41 | ||
37 | - {op: 'YB_SHOW_EVENT',}, | 42 | + {op: 'YB_SHOW_EVENT'}, |
43 | + {op: 'YB_SHOW_EVENT'}, | ||
38 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光1469', equals: { SUB_C_ID:'1469'}}, | 44 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光1469', equals: { SUB_C_ID:'1469'}}, |
39 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光2073', equals: { SUB_C_ID:'2073'}}, | 45 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光2073', equals: { SUB_C_ID:'2073'}}, |
40 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光1951', equals: { SUB_C_ID:'1951'}}, | 46 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光1951', equals: { SUB_C_ID:'1951'}}, |
41 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光1', equals: { SUB_C_ID:'1'}}, | 47 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光1', equals: { SUB_C_ID:'1'}}, |
42 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光2', equals: { SUB_C_ID:'2'}}, | 48 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光2', equals: { SUB_C_ID:'2'}}, |
43 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光3', equals: { SUB_C_ID:'3'}}, | 49 | {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光3', equals: { SUB_C_ID:'3'}}, |
50 | + {op: 'YB_CHOOSE_FOR_YOU', name: '首页猜你喜欢接口曝光有食', equals: { SUB_C_ID:'2077'}}, | ||
51 | + {op: 'YB_CHOOSE_FOR_YOU', name: '默认的首页猜你喜欢接口曝光'}, | ||
44 | 52 | ||
45 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首次启动默认tab上报'}, | 53 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首次启动默认tab上报'}, |
46 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel1', equals: { CHANNEL_ID: '1', SUB_C_ID:'1'}}, | 54 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel1', equals: { CHANNEL_ID: '1', SUB_C_ID:'1'}}, |
@@ -49,6 +57,7 @@ module.exports = { | @@ -49,6 +57,7 @@ module.exports = { | ||
49 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel2073', equals: { CHANNEL_ID: '2073', SUB_C_ID:'2073'}}, | 57 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel2073', equals: { CHANNEL_ID: '2073', SUB_C_ID:'2073'}}, |
50 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel1951', equals: { CHANNEL_ID: '1951', SUB_C_ID:'1951'}}, | 58 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel1951', equals: { CHANNEL_ID: '1951', SUB_C_ID:'1951'}}, |
51 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel1469', equals: { CHANNEL_ID: '1469', SUB_C_ID:'1469'}}, | 59 | {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel1469', equals: { CHANNEL_ID: '1469', SUB_C_ID:'1469'}}, |
60 | + {op: 'YB_HOME_CHANNEL_TAB_C', name: '首页内tab_channel有食', equals: { CHANNEL_ID: '2077', SUB_C_ID:'2077'}}, | ||
52 | 61 | ||
53 | {op: 'YB_MAIN_LT_CHS'},//侧边栏 | 62 | {op: 'YB_MAIN_LT_CHS'},//侧边栏 |
54 | {op: 'YB_AUTO_TRACK', name: '侧边栏点击',validate: (log) => { | 63 | {op: 'YB_AUTO_TRACK', name: '侧边栏点击',validate: (log) => { |
@@ -6,7 +6,7 @@ module.exports = { | @@ -6,7 +6,7 @@ module.exports = { | ||
6 | [iOS_TAB_MINE]:[ | 6 | [iOS_TAB_MINE]:[ |
7 | {op: 'UFO_MY_ITEM_C', name: '我的收入'}, | 7 | {op: 'UFO_MY_ITEM_C', name: '我的收入'}, |
8 | // {op: 'UFO_MY_ITEM_C', name: '商家入驻'}, | 8 | // {op: 'UFO_MY_ITEM_C', name: '商家入驻'}, |
9 | - {op: 'UFO_MY_ITEM_C', name: '新的好物'}, | 9 | + // {op: 'UFO_MY_ITEM_C', name: '新的好物'}, |
10 | {op: 'YB_PAGE_ENTER', name: '新的好物载入'}, | 10 | {op: 'YB_PAGE_ENTER', name: '新的好物载入'}, |
11 | {op: 'YB_PAGE_EXIT', name: '新的好物载出'}, | 11 | {op: 'YB_PAGE_EXIT', name: '新的好物载出'}, |
12 | // {op: 'YB_PAGE_ENTER', name: '商家入驻载入'}, | 12 | // {op: 'YB_PAGE_ENTER', name: '商家入驻载入'}, |
@@ -65,4 +65,51 @@ describe(iOS_BUSINESS_SHOPPING,'购物车', async(driver) => { | @@ -65,4 +65,51 @@ describe(iOS_BUSINESS_SHOPPING,'购物车', async(driver) => { | ||
65 | // await touchTab.click(); | 65 | // await touchTab.click(); |
66 | 66 | ||
67 | await driver.sleep(ACTION_PAUSE_TIME); | 67 | await driver.sleep(ACTION_PAUSE_TIME); |
68 | + | ||
69 | + touchTab = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther/XCUIElementTypeOther[1]/XCUIElementTypeOther[2]/XCUIElementTypeTabBar/XCUIElementTypeButton[5]',FIND_VIEW_OVER_TIME); | ||
70 | + await touchTab.click(); | ||
71 | + | ||
72 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
73 | + | ||
74 | + touchTab = await driver.waitForElementByAccessibilityId('mine_order_payment_new', FIND_VIEW_OVER_TIME); | ||
75 | + await touchTab.click(); | ||
76 | + | ||
77 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
78 | + | ||
79 | + // touchTab = await driver.waitForElementByAccessibilityId('立即付款', FIND_VIEW_OVER_TIME); | ||
80 | + // await touchTab.click(); | ||
81 | + | ||
82 | + // await driver.sleep(ACTION_PAUSE_TIME); | ||
83 | + | ||
84 | + // touchTab = await driver.waitForElementByAccessibilityId('yh_base_vc_back_btn', FIND_VIEW_OVER_TIME); | ||
85 | + // await touchTab.click(); | ||
86 | + | ||
87 | + // await driver.sleep(ACTION_PAUSE_TIME); | ||
88 | + | ||
89 | + // touchTab = await driver.waitForElementByAccessibilityId('确认离开', FIND_VIEW_OVER_TIME); | ||
90 | + // await touchTab.click(); | ||
91 | + | ||
92 | + // await driver.sleep(ACTION_PAUSE_TIME); | ||
93 | + | ||
94 | + touchTab = await driver.waitForElementByAccessibilityId('取消订单', FIND_VIEW_OVER_TIME); | ||
95 | + await touchTab.click(); | ||
96 | + | ||
97 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
98 | + | ||
99 | + touchTab = await driver.waitForElementByAccessibilityId('确定', FIND_VIEW_OVER_TIME); | ||
100 | + await touchTab.click(); | ||
101 | + | ||
102 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
103 | + | ||
104 | + console.log('完成事件'); | ||
105 | + touchTab = await driver.waitForElementByAccessibilityId('完成', FIND_VIEW_OVER_TIME); | ||
106 | + | ||
107 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
108 | + | ||
109 | + action = new wd.TouchAction(driver); | ||
110 | + action.longPress({x: 100, y: 150}) | ||
111 | + .moveTo({x: 100, y: 250}) | ||
112 | + .release(); | ||
113 | + await action.perform(); | ||
114 | + | ||
68 | }); | 115 | }); |
@@ -11,52 +11,76 @@ describe(IOS_PRODUCT_DETAIL, '商品详情页埋点测试', async(driver) => { | @@ -11,52 +11,76 @@ describe(IOS_PRODUCT_DETAIL, '商品详情页埋点测试', async(driver) => { | ||
11 | await category.click(); | 11 | await category.click(); |
12 | console.log("点击分类完成"); | 12 | console.log("点击分类完成"); |
13 | 13 | ||
14 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
15 | + | ||
14 | //点击其中的一个商品 | 16 | //点击其中的一个商品 |
15 | let firstProduct = await driver.waitForElementByAccessibilityId('yh_prd_cell_0_3', FIND_VIEW_OVER_TIME); | 17 | let firstProduct = await driver.waitForElementByAccessibilityId('yh_prd_cell_0_3', FIND_VIEW_OVER_TIME); |
16 | await firstProduct.click(); | 18 | await firstProduct.click(); |
17 | console.log("点击其中一个商品完成"); | 19 | console.log("点击其中一个商品完成"); |
20 | + | ||
21 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
22 | + | ||
18 | //进入购物车 | 23 | //进入购物车 |
19 | let goToShopCart = await driver.waitForElementByAccessibilityId('yh_prd_detail_shopcart_btn', FIND_VIEW_OVER_TIME); | 24 | let goToShopCart = await driver.waitForElementByAccessibilityId('yh_prd_detail_shopcart_btn', FIND_VIEW_OVER_TIME); |
20 | await goToShopCart.click(); | 25 | await goToShopCart.click(); |
21 | console.log("进入购物车完成"); | 26 | console.log("进入购物车完成"); |
27 | + | ||
28 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
29 | + | ||
22 | //返回商品详情 | 30 | //返回商品详情 |
23 | let backPrdDetail = await driver.waitForElementByAccessibilityId('yh_base_vc_back_btn', FIND_VIEW_OVER_TIME); | 31 | let backPrdDetail = await driver.waitForElementByAccessibilityId('yh_base_vc_back_btn', FIND_VIEW_OVER_TIME); |
24 | await backPrdDetail.click(); | 32 | await backPrdDetail.click(); |
25 | console.log("返回详情完成"); | 33 | console.log("返回详情完成"); |
34 | + | ||
35 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
36 | + | ||
26 | //点击分享 | 37 | //点击分享 |
27 | let tapShare = await driver.waitForElementByAccessibilityId('shareActionBtn', FIND_VIEW_OVER_TIME); | 38 | let tapShare = await driver.waitForElementByAccessibilityId('shareActionBtn', FIND_VIEW_OVER_TIME); |
28 | await tapShare.click(); | 39 | await tapShare.click(); |
29 | console.log("点击分享完成"); | 40 | console.log("点击分享完成"); |
41 | + | ||
42 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
43 | + | ||
30 | //取消分享 | 44 | //取消分享 |
31 | let cancelShare = await driver.waitForElementByAccessibilityId('取消', FIND_VIEW_OVER_TIME); | 45 | let cancelShare = await driver.waitForElementByAccessibilityId('取消', FIND_VIEW_OVER_TIME); |
32 | await cancelShare.click(); | 46 | await cancelShare.click(); |
33 | console.log("取消完成"); | 47 | console.log("取消完成"); |
48 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
49 | + | ||
34 | let tapMore = await driver.waitForElementByAccessibilityId('moreActionBtn', FIND_VIEW_OVER_TIME); | 50 | let tapMore = await driver.waitForElementByAccessibilityId('moreActionBtn', FIND_VIEW_OVER_TIME); |
35 | await tapMore.click(); | 51 | await tapMore.click(); |
36 | console.log("点击更多"); | 52 | console.log("点击更多"); |
53 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
54 | + | ||
37 | let cancelMore = await driver.waitForElementByAccessibilityId('quick_jump_bg_view', FIND_VIEW_OVER_TIME); | 55 | let cancelMore = await driver.waitForElementByAccessibilityId('quick_jump_bg_view', FIND_VIEW_OVER_TIME); |
38 | await cancelMore.click(); | 56 | await cancelMore.click(); |
39 | console.log("取消更多"); | 57 | console.log("取消更多"); |
58 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
40 | //点击加入购物车 | 59 | //点击加入购物车 |
41 | let addToCart = await driver.waitForElementByAccessibilityId('加入购物车', FIND_VIEW_OVER_TIME); | 60 | let addToCart = await driver.waitForElementByAccessibilityId('加入购物车', FIND_VIEW_OVER_TIME); |
42 | await addToCart.click(); | 61 | await addToCart.click(); |
43 | console.log("点击选择颜色尺码弹窗完成"); | 62 | console.log("点击选择颜色尺码弹窗完成"); |
63 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
44 | //选择颜色 | 64 | //选择颜色 |
45 | let chooseColor = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther[2]/XCUIElementTypeOther/XCUIElementTypeTable/XCUIElementTypeCell[1]/XCUIElementTypeStaticText[1]', FIND_VIEW_OVER_TIME); | 65 | let chooseColor = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther[2]/XCUIElementTypeOther/XCUIElementTypeTable/XCUIElementTypeCell[1]/XCUIElementTypeStaticText[1]', FIND_VIEW_OVER_TIME); |
46 | await chooseColor.click(); | 66 | await chooseColor.click(); |
47 | console.log("完成选择颜色"); | 67 | console.log("完成选择颜色"); |
68 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
48 | //选择尺码 | 69 | //选择尺码 |
49 | let chooseSize = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther[2]/XCUIElementTypeOther/XCUIElementTypeTable/XCUIElementTypeCell[2]/XCUIElementTypeStaticText[1]', FIND_VIEW_OVER_TIME); | 70 | let chooseSize = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther[2]/XCUIElementTypeOther/XCUIElementTypeTable/XCUIElementTypeCell[2]/XCUIElementTypeStaticText[1]', FIND_VIEW_OVER_TIME); |
50 | await chooseSize.click(); | 71 | await chooseSize.click(); |
51 | console.log("完成选择尺码"); | 72 | console.log("完成选择尺码"); |
73 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
52 | //加一下 | 74 | //加一下 |
53 | let chooseAdd = await driver.waitForElementByAccessibilityId('yh_choose_view_add_btn', FIND_VIEW_OVER_TIME); | 75 | let chooseAdd = await driver.waitForElementByAccessibilityId('yh_choose_view_add_btn', FIND_VIEW_OVER_TIME); |
54 | await chooseAdd.click(); | 76 | await chooseAdd.click(); |
55 | console.log("点击加一件"); | 77 | console.log("点击加一件"); |
78 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
56 | //减一下 | 79 | //减一下 |
57 | let chooseReduce = await driver.waitForElementByAccessibilityId('yh_choose_view_reduce_btn', FIND_VIEW_OVER_TIME); | 80 | let chooseReduce = await driver.waitForElementByAccessibilityId('yh_choose_view_reduce_btn', FIND_VIEW_OVER_TIME); |
58 | await chooseReduce.click(); | 81 | await chooseReduce.click(); |
59 | console.log("点击减一件"); | 82 | console.log("点击减一件"); |
83 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
60 | //点击加入购物车 | 84 | //点击加入购物车 |
61 | let add = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther[2]/XCUIElementTypeOther/XCUIElementTypeButton[2]', FIND_VIEW_OVER_TIME); | 85 | let add = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther[2]/XCUIElementTypeOther/XCUIElementTypeButton[2]', FIND_VIEW_OVER_TIME); |
62 | await add.click(); | 86 | await add.click(); |
1 | const wd = require('wd'); | 1 | const wd = require('wd'); |
2 | const {describe} = require('../../libs/driver'); | 2 | const {describe} = require('../../libs/driver'); |
3 | const {iOS_TAB_HOME} = require('../../scene-types/scene-types'); | 3 | const {iOS_TAB_HOME} = require('../../scene-types/scene-types'); |
4 | +const { FIND_VIEW_OVER_TIME, ACTION_PAUSE_TIME } = require('../../config/constant'); | ||
4 | 5 | ||
5 | describe(iOS_TAB_HOME,'首页', async(driver) => { | 6 | describe(iOS_TAB_HOME,'首页', async(driver) => { |
6 | let touchTab = await driver.waitForElementByAccessibilityId('home drawer entrance',10000); | 7 | let touchTab = await driver.waitForElementByAccessibilityId('home drawer entrance',10000); |
@@ -11,7 +12,7 @@ describe(iOS_TAB_HOME,'首页', async(driver) => { | @@ -11,7 +12,7 @@ describe(iOS_TAB_HOME,'首页', async(driver) => { | ||
11 | }, 2000); | 12 | }, 2000); |
12 | }) | 13 | }) |
13 | await (new wd.TouchAction(driver)) | 14 | await (new wd.TouchAction(driver)) |
14 | - .press({x: 300, y: 158}) | 15 | + .longPress({x: 300, y: 158}) |
15 | .moveTo({x: 290, y: 162}) | 16 | .moveTo({x: 290, y: 162}) |
16 | .release() | 17 | .release() |
17 | .perform() | 18 | .perform() |
@@ -28,21 +29,38 @@ describe(iOS_TAB_HOME,'首页', async(driver) => { | @@ -28,21 +29,38 @@ describe(iOS_TAB_HOME,'首页', async(driver) => { | ||
28 | touchTab = await driver.waitForElementByAccessibilityId('球鞋',5000); | 29 | touchTab = await driver.waitForElementByAccessibilityId('球鞋',5000); |
29 | await touchTab.click(); | 30 | await touchTab.click(); |
30 | 31 | ||
32 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
33 | + | ||
31 | touchTab = await driver.waitForElementByAccessibilityId('男装', 5000); | 34 | touchTab = await driver.waitForElementByAccessibilityId('男装', 5000); |
32 | await touchTab.click(); | 35 | await touchTab.click(); |
33 | 36 | ||
37 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
38 | + | ||
34 | touchTab = await driver.waitForElementByAccessibilityId('女装',5000); | 39 | touchTab = await driver.waitForElementByAccessibilityId('女装',5000); |
35 | await touchTab.click(); | 40 | await touchTab.click(); |
36 | 41 | ||
42 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
43 | + | ||
37 | touchTab = await driver.waitForElementByAccessibilityId('生活方式',5000); | 44 | touchTab = await driver.waitForElementByAccessibilityId('生活方式',5000); |
38 | await touchTab.click(); | 45 | await touchTab.click(); |
39 | 46 | ||
47 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
48 | + | ||
40 | touchTab = await driver.waitForElementByAccessibilityId('高街BLK', 1000); | 49 | touchTab = await driver.waitForElementByAccessibilityId('高街BLK', 1000); |
41 | await touchTab.click(); | 50 | await touchTab.click(); |
42 | 51 | ||
52 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
53 | + | ||
43 | touchTab = await driver.waitForElementByAccessibilityId('潮童',5000); | 54 | touchTab = await driver.waitForElementByAccessibilityId('潮童',5000); |
44 | await touchTab.click(); | 55 | await touchTab.click(); |
45 | 56 | ||
57 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
58 | + | ||
59 | + touchTab = await driver.waitForElementByAccessibilityId('有食',5000); | ||
60 | + await touchTab.click(); | ||
61 | + | ||
62 | + await driver.sleep(ACTION_PAUSE_TIME); | ||
63 | + | ||
46 | touchTab = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther/XCUIElementTypeOther[1]/XCUIElementTypeOther[2]/XCUIElementTypeTabBar/XCUIElementTypeButton[1]',5000); | 64 | touchTab = await driver.waitForElementByXPath('//XCUIElementTypeApplication[@name="Yoho!Buy有货"]/XCUIElementTypeWindow[1]/XCUIElementTypeOther/XCUIElementTypeOther[1]/XCUIElementTypeOther[2]/XCUIElementTypeTabBar/XCUIElementTypeButton[1]',5000); |
47 | await touchTab.click(); | 65 | await touchTab.click(); |
48 | 66 |
@@ -37,7 +37,7 @@ describe(iOS_TAB_MINE,'我的', async(driver) => { | @@ -37,7 +37,7 @@ describe(iOS_TAB_MINE,'我的', async(driver) => { | ||
37 | // await touchTab.click(); | 37 | // await touchTab.click(); |
38 | 38 | ||
39 | // await driver.sleep(ACTION_PAUSE_TIME); | 39 | // await driver.sleep(ACTION_PAUSE_TIME); |
40 | -// s | 40 | +// |
41 | // let element = await driver.elementsByAccessibilityId("完善信息"); | 41 | // let element = await driver.elementsByAccessibilityId("完善信息"); |
42 | // let isDisplayed = await element.isDisplayed(); | 42 | // let isDisplayed = await element.isDisplayed(); |
43 | // if (isDisplayed){ | 43 | // if (isDisplayed){ |
@@ -47,23 +47,21 @@ describe(iOS_TAB_MINE,'我的', async(driver) => { | @@ -47,23 +47,21 @@ describe(iOS_TAB_MINE,'我的', async(driver) => { | ||
47 | 47 | ||
48 | // await driver.sleep(ACTION_PAUSE_TIME); | 48 | // await driver.sleep(ACTION_PAUSE_TIME); |
49 | 49 | ||
50 | - // touchTab = await driver.waitForElementByAccessibilityId('yh_base_vc_back_btn', FIND_VIEW_OVER_TIME); | 50 | + // touchTab = await driver.waitForElementByAccessibilityId('新的好物 没有你的好物?申请上架', FIND_VIEW_OVER_TIME); |
51 | // await touchTab.click(); | 51 | // await touchTab.click(); |
52 | 52 | ||
53 | - // await driver.sleep(ACTION_PAUSE_TIME); | ||
54 | - | ||
55 | - touchTab = await driver.waitForElementByAccessibilityId('新的好物 没有你的好物?申请上架', FIND_VIEW_OVER_TIME); | ||
56 | - await touchTab.click(); | 53 | + // await driver.sleep(4000); |
57 | 54 | ||
58 | - await driver.sleep(4000); | 55 | + // console.log("新的好物退出"); |
56 | + // let action = new wd.TouchAction(driver); | ||
57 | + // action.press({x: 10, y: 10}) | ||
58 | + // .moveTo({x: 50, y: 10}) | ||
59 | + // .release(); | ||
60 | + // await action.perform(); | ||
59 | 61 | ||
60 | - let action = new wd.TouchAction(driver); | ||
61 | - action.press({x: 10, y: 10}) | ||
62 | - .moveTo({x: 50, y: 50}) | ||
63 | - .release(); | ||
64 | - await action.perform(); | 62 | + // await driver.sleep(ACTION_PAUSE_TIME); |
65 | 63 | ||
66 | - await driver.sleep(ACTION_PAUSE_TIME); | 64 | + // console.log("退出球鞋交易"); |
67 | 65 | ||
68 | touchTab = await driver.waitForElementByAccessibilityId('yh_base_vc_back_btn', FIND_VIEW_OVER_TIME); | 66 | touchTab = await driver.waitForElementByAccessibilityId('yh_base_vc_back_btn', FIND_VIEW_OVER_TIME); |
69 | await touchTab.click(); | 67 | await touchTab.click(); |
-
Please register or login to post a comment