PARTNERS006_partner_remove.yml 970 字节
config:
    name: PARTNERS006-有业务数据的合伙人不能删除
    base_url: ${ENV(base_manager_url)}

teststeps:
-   name: $phone 登录系统
    variables:
      phone: ${ENV(adminphone)}
    testcase: testcases/common/m_login_testcases.yml

-   name: 新增合伙人
    api:  api/m_api/partners/m_partner_add_api.yml
    extract:
        - partnerid: content.data.id
    validate:
        - equals:
            - content.msg
            - ok


-   name: 新增实发订单
    variables:
        partnerID: $partnerid
        saleDate: ${get_today()}
    api: api/m_api/actual/m_add_order_actual_api.yml
    extract:
        - orderid: content.data.id
    validate:
        - eq:
          - content.msg
          - ok

-   name: 删除合伙人
    variables:
        id: $partnerid
    api:  api/m_api/partners/m_partner_remove_api.yml
    validate:
        - equals:
            - content.msg
            - '该合伙人有业务数据,不可删除!'