smartpush 1.5.2__py3-none-any.whl → 1.5.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -20,6 +20,8 @@ class URL(Enum):
20
20
  :type 表单操作
21
21
  """
22
22
  deleteForm = '/form/deleteFormInfo', 'GET'
23
+ getFormList = '/form/getFormList', 'POST'
24
+ getFormInfo = 'form/getFormInfo','GET'
23
25
 
24
26
  @property
25
27
  def method(self):
@@ -1,13 +1,13 @@
1
1
  import json
2
2
  from tenacity import retry, stop_after_attempt, wait_fixed
3
- from smartpush.base.request_base import RequestBase, FormRequestBase
3
+ from smartpush.base.request_base import FormRequestBase
4
4
  from smartpush.base.url_enum import URL
5
5
  from smartpush.export.basic.GetOssUrl import log_attempt
6
6
 
7
7
 
8
8
  class FormAfter(FormRequestBase):
9
9
  def __init__(self, form_id, headers, host):
10
- super().__init__(form_id,headers, host)
10
+ super().__init__(form_id, headers, host)
11
11
 
12
12
  @retry(stop=stop_after_attempt(3), wait=wait_fixed(2), after=log_attempt)
13
13
  def callPageFormReportDetail(self, reportDetailType, start_time=None, end_time=None):
@@ -69,6 +69,20 @@ class FormAfter(FormRequestBase):
69
69
  result.raise_for_status()
70
70
  return result['resultData']
71
71
 
72
+ @retry(stop=stop_after_attempt(3), wait=wait_fixed(2), after=log_attempt)
73
+ def callGetFormList(self, formName):
74
+ params = {'page': 1, 'pageSize': 10, 'name': formName}
75
+ result = self.post(url=self.host + URL.getFormList.url, data=params).json()
76
+ result.raise_for_status()
77
+ return result["resultData"]['datas']
78
+
79
+ @retry(stop=stop_after_attempt(3), wait=wait_fixed(2), after=log_attempt)
80
+ def callGetFormInfo(self):
81
+ params = {'formId': self.form_id}
82
+ result = self.get(url=self.host + URL.getFormInfo.url, params=params).json()
83
+ result.raise_for_status()
84
+ return result['resultData']
85
+
72
86
  @retry(stop=stop_after_attempt(3), wait=wait_fixed(2), after=log_attempt)
73
87
  def callDeleteForm(self, merchant_id):
74
88
  params = {"formId": self.form_id, "merchant_id": merchant_id}
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: smartpush
3
- Version: 1.5.2
3
+ Version: 1.5.3
4
4
  Summary: 用于smartpush自动化测试工具包
5
5
  Author: lulu、felix、long
6
6
 
@@ -3,7 +3,7 @@ smartpush/get_jira_info.py,sha256=OYaDV6VPAmkGKYLlRnsi1ZyKHU8xEiVnjsYrc41ZR0U,17
3
3
  smartpush/base/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
4
  smartpush/base/faker_data.py,sha256=TOd5EKVImxZpsKEW_dtKa2iqiUGqU7OBkOM8pvqKVUc,24643
5
5
  smartpush/base/request_base.py,sha256=Fn1uPWgaZQZdu8yyi2n13nuiKPVeR95iwx99sG6XGVU,574
6
- smartpush/base/url_enum.py,sha256=xj98cd22sZ39TzKfhVEERgSJ1WScn7R4HVU-z8KTbM8,874
6
+ smartpush/base/url_enum.py,sha256=PmMwG10p9OqjCgfVduJTvb88YDoygl6lI1Pt8XkL0VA,963
7
7
  smartpush/export/__init__.py,sha256=D9GbWcmwnetEndFDty5XbVienFK1WjqV2yYcQp3CM84,99
8
8
  smartpush/export/basic/ExcelExportChecker.py,sha256=3IAeu1kjFS4MpDxjVB1htAcRA1BtfpH3xEkZyP4htAA,19963
9
9
  smartpush/export/basic/GetOssUrl.py,sha256=LeF1y1_uJaYXth1KvO6mEDS29ezb9tliBv5SrbqYkXc,6136
@@ -12,7 +12,7 @@ smartpush/export/basic/__init__.py,sha256=6tcrS-2NSlsJo-UwEsnGUmwCf7jgOsh_UEbM0F
12
12
  smartpush/flow/MockFlow.py,sha256=MI8WIMZyKlxrV5QVs8rXX6iD07Ldl37_L5Yb5FWqHzU,8595
13
13
  smartpush/flow/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
14
14
  smartpush/form/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
15
- smartpush/form/form_after.py,sha256=vuxtOnADC0PJd53h_KM9yEfVpeQHIC8JTPrRE8bw7VA,6225
15
+ smartpush/form/form_after.py,sha256=_Sq-QE1_HRUOJFH6_WIbXkqV4Z3fPOcBdsvcAGAiEUc,6866
16
16
  smartpush/form/form_assert.py,sha256=wPIRfQHhr7lN1fFd-mp0z_qKMtF4jfrNxRWvp2xfqCg,257
17
17
  smartpush/form/form_before.py,sha256=CCvAC_2yWPlnQGtjEA8LPLy9853Nq3nNjcL2GewFWIs,175
18
18
  smartpush/form/form_client_operation.py,sha256=gg-5uHXCyMa_ypBSYPYFVxXdwZdYBJsNtUCqayknMBw,303
@@ -22,7 +22,7 @@ smartpush/utils/ListDictUtils.py,sha256=Fm5_d7UyY6xB8gySMPdl5jIFSRhXZcYXdYW-_L1a
22
22
  smartpush/utils/StringUtils.py,sha256=n8mo9k0JQN63MReImgv-66JxmmymOGknR8pH2fkQrAo,4139
23
23
  smartpush/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
24
24
  smartpush/utils/form_utils.py,sha256=ld-g_Dm_ZlnagQt7imYfUc87bcBRVlTctywuLtzmjXQ,849
25
- smartpush-1.5.2.dist-info/METADATA,sha256=MOQLSgRKyErD-iK5bpZI1r5F2poLsWA2d7vM2fWg8PI,131
26
- smartpush-1.5.2.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
27
- smartpush-1.5.2.dist-info/top_level.txt,sha256=5_CXqu08EfbPaKLjuSAOAqCmGU6shiatwDU_ViBGCmg,10
28
- smartpush-1.5.2.dist-info/RECORD,,
25
+ smartpush-1.5.3.dist-info/METADATA,sha256=3G1HMXQMe5tTBYuShoRgtfvmqElJsLD_FfYk4JY2VzU,131
26
+ smartpush-1.5.3.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
27
+ smartpush-1.5.3.dist-info/top_level.txt,sha256=5_CXqu08EfbPaKLjuSAOAqCmGU6shiatwDU_ViBGCmg,10
28
+ smartpush-1.5.3.dist-info/RECORD,,