api1: title: 新增shopify - 商店集成 url: /api/v1/shop/add method: post data: {"domain":"${append_shop_url}","shopName":"${append_shop_name}","source":2,"v":"${v}"} set_value: {"append_shop_id": "$.data.id"} expected: - eq: {"$.code" : 0} api2: title: 新增shopify - js集成 url: /api/v1/shop/add method: post data: {"domain": "${append_js_shop_url}","shopName": "${append_js_shop_name}","source": 1,"v": "${v}" } set_value: {"append_js_id": "$.data.id"} expected: - eq: { "$.code": 0 } api3: title: 检查店铺是否添加成功 url: /api/v1/shop/local/shopInfoList method: post before_sql: setting/shopifyIntegration/shopifyIntegration_shop_select.py data: {"omitShopSet":true,"omitEmbedding":true,"havePreShop":true,"v":"${v}"} expected: - eq: {"$.code" : 0} - in_list: {"$.data.list[*].id": "${append_shop_id}"} - in_list: {"$.data.list[*].id": "${append_js_id}"} api4: title: 检查店铺信息 url: /api/v1/shop/local/shopInfoList method: post before_sql: setting/shopifyIntegration/shopifyIntegration_shop_num_select.py data: {"omitShopSet":true,"omitEmbedding":true,"havePreShop":true,"v":"${v}"} expected: - eq: {"$.code" : 0} - eq: {"$.data.list[?(@.id == ${shop_id})].brandId": "${shop_brand_id}"} - eq: {"$.data.list[?(@.id == ${shop_id})].companyId": "${shop_company_id}"} - eq: {"$.data.list[?(@.id == ${shop_id})].shopName": "${shop_name}"} - eq: {"$.data.list[?(@.id == ${shop_id})].shopDomain": "${shop_domain}"} - eq: {"$.data.list[?(@.id == ${shop_id})].email": "${shop_email}" } - eq: {"$.data.list[?(@.id == ${shop_id})].shopJs": "${shop_js}" } - eq: {"$.data.list[?(@.id == ${shop_id})].integratedEmail": "${shop_integrated_email}" } - eq: {"$.data.list[?(@.id == ${shop_id})].faqWilldeskDoamin": "${shop_faq_willdesk_domain}" } - eq: {"$.data.list[?(@.id == ${shop_id})].faqCnameDomain": "${shop_faq_cname_domain}" } - eq: {"$.data.list[?(@.id == ${shop_id})].currency": "${shop_currency}" } - eq: {"$.data.list[?(@.id == ${shop_id})].connectStatus": "${shop_connect_status}" } - eq: {"$.data.list[?(@.id == ${shop_id})].thirdId": "${shop_third_id}" } # - exec: {"code": "assert len(res.json()['data']['list']) == ${shop_num}"} api5: title: 更新店铺信息 url: /api/v1/shop/edit method: post data: {"id":"${append_shop_id}","shopName":"${update_shop_name}","v":"${v}"} expected: - eq: {"$.code" : 0} api6: title: 关联店铺邮箱 url: /api/v1/shop/local/updateShopIntegratedEmail method: post data: {"shopId":"${append_shop_id}","integratedEmail":"${active_shop_email}","v":"${v}"} expected: - eq: {"$.code" : 0} api7: title: 检查店铺信息 url: /api/v1/shop/local/shopInfoList method: post data: {"omitShopSet":true,"omitEmbedding":true,"havePreShop":true,"v":"${v}"} expected: - eq: {"$.code" : 0} - eq: {"$.data.list[?(@.id == ${append_shop_id})].integratedEmail": "${active_shop_email}" } - eq: {"$.data.list[?(@.id == ${append_shop_id})].shopName": "${update_shop_name}" } api8: title: 删除店铺 url: /api/v1/shop/delete method: post data: {"shopId":"${append_shop_id}","v":"${v}"} expected: - eq: {"$.code" : 0} api9: title: 删除店铺 url: /api/v1/shop/delete method: post data: {"shopId":"${append_js_id}","v":"${v}"} expected: - eq: {"$.code" : 0} api10: title: 检查店铺是否删除成功 url: /api/v1/shop/local/shopInfoList method: post data: {"omitShopSet": true,"omitEmbedding": true,"havePreShop": true,"v": "${v}" } expected: - eq: { "$.code": 0 } - not_in_list: {"$.data.list[*].id": "${append_shop_id}"} - not_in_list: {"$.data.list[*].id": "${append_js_id}"} api11: title: 编辑工作区名称 url: /api/v1/brand/changeName method: post data: {name: "${new_workspance_name}", v: "${v}"} expected: - eq: {"$.code": 0 } api12: title: 检查工作区名称是否更新 url: /api/v1/customerService/getCustomerServiceInfo?v=${v} method: get expected: - eq: {"$.code": 0 } - eq: {"$.data.brandName": "${new_workspance_name}" } api13: title: 还原工作区名称 url: /api/v1/brand/changeName method: post data: {name: "${brandName}", v: "${v}"} expected: - eq: {"$.code": 0 } api14: title: 检查工作区名称是否还原 url: /api/v1/customerService/getCustomerServiceInfo?v=${v} method: get expected: - eq: {"$.code": 0 } - eq: {"$.data.brandName": "${brandName}" } api15: title: 检查集成数量 url: /api/v1/resource/getResourceCount method: post data: {"v":"${v}"} before_sql: setting/shopifyIntegration/shopifyIntegration_integration_num_select.py expected: - eq: {"$.code" : 0} - eq: {"$.data.list[?(@.resourceName == 'ShopifyShop')].success": "${shopify_shop_num}"} - eq: {"$.data.list[?(@.resourceName == 'JsShop')].success": "${js_shop_num}"} - eq: {"$.data.list[?(@.resourceName == 'Messenger')].success": "${facebook_shop_num}"} - eq: {"$.data.list[?(@.resourceName == 'Email')].success": "${email_shop_num}"} - eq: {"$.data.list[?(@.resourceName == 'Instagram')].success": "${ins_shop_num}"} - eq: {"$.data.list[?(@.resourceName == 'Whatsapp')].success": "${whatsapp_shop_num}"} - eq: {"$.data.list[?(@.resourceName == 'Macro')].success": "${macro_num}"}