作者 dengyuting

fix

... ... @@ -21,6 +21,9 @@ def sleep(n_secs):
def convert_to_string(value):
return str(value)
def convert_to_int(value):
return int(value)
def get_nowtime():
return time.strftime("%Y%m%d%H%M%S",time.localtime(time.time()))
... ...
... ... @@ -14,8 +14,9 @@ def cal_orderPrice(univalence, *args):
def cal_Ratio(ratio, univalence, *args):
price = cal_orderPrice(univalence, *args)
sum = ratio/100 * price
return sum
# print(str(int(sum)))
return str(int(sum))
# cal_Ratio(10,15,300)
def add(x, y):
"""
... ...
... ... @@ -31,7 +31,7 @@ teststeps:
#####合伙人已收分红总额
- eq:
- content.data.order.receivedDividends
- 0
- ${convert_to_string(0)}
#####合伙人未收分红总额
- eq:
- content.data.order.notReceivedDividend
... ... @@ -47,7 +47,7 @@ teststeps:
#####产品1总金额
- eq:
- content.data.product.detail.0.commodityPrice
- ${convert_to_string(1500)}
- 1500
#####产品1应收分红
- eq:
- content.data.product.detail.0.partnerDividends
... ... @@ -59,7 +59,7 @@ teststeps:
#####产品2总金额
- eq:
- content.data.product.detail.1.commodityPrice
- ${convert_to_string(3000)}
- 3000
#####产品2应收分红
- eq:
- content.data.product.detail.1.partnerDividends
... ...
... ... @@ -54,23 +54,23 @@ teststeps:
validate:
- eq:
- content.data.order.orderId
- ${convert_to_string($actual_id)}
- $actual_id
#####合伙人未收分红总额
- eq:
- content.data.order.notReceivedDividend
- 0
- ${convert_to_string(375)}
#####合伙人已收分红总额
- eq:
- content.data.order.receivedDividends
- 0
- ${convert_to_string(0)}
#####合伙人应收分红总额
- eq:
- content.data.order.partnerDividends
- 375
- ${convert_to_string(375)}
#####合伙人分红支出总额
- eq:
- content.data.order.dividendSpending
- 0
- ${convert_to_string(0)}
#####初始总数量
- eq:
- content.data.product.orderNumCount
... ... @@ -82,38 +82,38 @@ teststeps:
#####合伙人应收分红总额调整
- eq:
- content.data.product.partnerDividendsCount
- 375
- ${convert_to_string(375)}
#####产品1是否正确
- eq:
- content.data.product.0.id
- $product_id_1
- content.data.product.detail.0.productId
- ${convert_to_int($product_id_1)}
#####产品1总金额
- eq:
- content.data.product.0.detail.commodityPrice
- content.data.product.detail.0.commodityPrice
- 750
#####产品1应收分红
- eq:
- content.data.product.0.detail.partnerDividends
- 75
- content.data.product.detail.0.partnerDividends
- ${convert_to_string(75)}
#####产品1数量调整
- eq:
- content.data.product.0.orderNum
- content.data.product.detail.0.orderNum
- $goodNumber
#####产品1分红状态
- eq:
- content.data.product.0.stateOfPayment
- content.data.product.detail.0.paymentStatus
- 1
#####产品2总金额
- eq:
- content.data.product.1.detail.commodityPrice
- content.data.product.detail.1.commodityPrice
- 3000
#####产品2应收分红
- eq:
- content.data.product.1.detail.partnerDividends
- 300
- content.data.product.detail.1.partnerDividends
- ${convert_to_string(300)}
#####产品2分红状态
- eq:
- content.data.product.1.stateOfPayment
- content.data.product.detail.1.paymentStatus
- 1
- name: 查看实际订单列表
... ...
... ... @@ -49,54 +49,54 @@ teststeps:
validate:
- eq:
- content.data.order.orderId
- ${convert_to_string($actual_id)}
- $actual_id
#####合伙人应收分红总额
- eq:
- content.data.order.partnerDividends
- 450
- ${convert_to_string(450)}
#####合伙人未收分红总额
- eq:
- content.data.order.notReceivedDividend
- 300
- ${convert_to_string(300)}
#####合伙人已收分红总额
- eq:
- content.data.order.receivedDividends
- 150
- ${convert_to_string(150)}
#####合伙人分红支出总额
- eq:
- content.data.order.dividendSpending
- 0
- ${convert_to_string(0)}
#####产品1是否正确
- eq:
- content.data.product.0.id
- $product_id_1
- content.data.product.detail.0.productId
- ${convert_to_int($product_id_1)}
#####产品1总金额
- eq:
- content.data.product.0.detail.commodityPrice
- content.data.product.detail.0.commodityPrice
- 1500
#####产品1应收分红
- eq:
- content.data.product.0.detail.partnerDividends
- 150
- content.data.product.detail.0.partnerDividends
- ${convert_to_string(150)}
#####产品1数量
- eq:
- content.data.product.0.orderNum
- content.data.product.detail.0.orderNum
- 100
#####产品1分红状态
- eq:
- content.data.product.0.stateOfPayment
- content.data.product.detail.0.paymentStatus
- 2
#####产品2总金额
- eq:
- content.data.product.1.detail.commodityPrice
- content.data.product.detail.1.commodityPrice
- 3000
#####产品2应收分红
- eq:
- content.data.product.1.detail.partnerDividends
- 300
- content.data.product.detail.1.partnerDividends
- ${convert_to_string(300)}
#####产品2分红状态
- eq:
- content.data.product.1.stateOfPayment
- content.data.product.detail.1.paymentStatus
- 1
- name: 查看实际订单列表
... ...
... ... @@ -67,55 +67,55 @@ teststeps:
api: api/m_api/dividends/m_dividends_detail_api.yml
validate:
- eq:
- content.data.order.id
- ${convert_to_string($actual_id)}
- content.data.order.orderId
- $actual_id
#####合伙人应收分红总额
- eq:
- content.data.order.partnerDividends
- 450
- ${convert_to_string(375)}
#####合伙人未收分红总额
- eq:
- content.data.order.notReceivedDividend
- 300
- ${convert_to_string(300)}
#####合伙人已收分红总额
- eq:
- content.data.order.receivedDividends
- 150
- ${convert_to_string(150)}
#####合伙人分红支出总额
- eq:
- content.data.order.dividendSpending
- 75
- ${convert_to_string(75)}
#####产品1是否正确
- eq:
- content.data.product.0.id
- $product_id_1
- content.data.product.detail.0.productId
- ${convert_to_int($product_id_1)}
#####产品1总金额
- eq:
- content.data.product.0.detail.commodityPrice
- 1500
- content.data.product.detail.0.commodityPrice
- 750
#####产品1应收分红
- eq:
- content.data.product.0.detail.partnerDividends
- 150
- content.data.product.detail.0.partnerDividends
- ${convert_to_string(75)}
#####产品1数量
- eq:
- content.data.product.0.orderNum
- 100
- content.data.product.detail.0.orderNum
- 50
#####产品1分红状态
- eq:
- content.data.product.0.stateOfPayment
- content.data.product.detail.0.paymentStatus
- 2
#####产品2总金额
- eq:
- content.data.product.1.detail.commodityPrice
- content.data.product.detail.1.commodityPrice
- 3000
#####产品2应收分红
- eq:
- content.data.product.1.detail.partnerDividends
- 300
- content.data.product.detail.1.partnerDividends
- ${convert_to_string(300)}
#####产品2分红状态
- eq:
- content.data.product.1.stateOfPayment
- content.data.product.detail.1.paymentStatus
- 1
- name: 查看实际订单列表
... ...