def test_014_api_78dk_sht__store_modifystorebasic_12managerphone(self): """ 新增门店基本信息:信息正确 :return: """ res = json.loads( ShtAction.test_api_78dk_sht__store_modifyStoreBasic( storeprovincecode='130000', leasetimebegin='2019-08-08', storename=store_name, leasetimeend='2020-08-08', employeesnum=100, storeregion='新华区', managername=name, managerphone=MockData.phone(12), storeuuid='', storecitycode='130100', storeregioncode='130105', area='1999', storeaddress='hxhhxhchchhchchcjcjj', storeprovince='河北省', idcardnumber=cardnumber, email=email, storecity='石家庄市')) Assertion.verity(res['msg'], '申请人电话格式不合法') Assertion.verity(res['code'], 'S0006')
def test_011_api_78dk_platform_om_bd_addBdInfo_12mobile(self): """ BD新增 12 mobile :return: """ res = PlatformAction.test_api_78dk_platform_om_bd_addBdInfo(channeluuid=channelid, email=email, mobile=MockData.phone(12), name=bd_name) Assertion.verity(json.loads(res)['code'], '20000') Assertion.verity(json.loads(res)['msg'], '手机格式不合法,')
def test_010_api_78dk_platform_om_bd_addBdInfo_10mobile(self): """ BD新增 10 mobile :return: """ res = WebAction.test_api_78dk_platform_om_bd_addBdInfo( email=email, mobile=MockData.phone(10), name=bd_name) Assertion.verity(json.loads(res)['code'], '20000') Assertion.verity(json.loads(res)['msg'], '手机格式不合法,')
def test_004_api_78dk_platform_sa_addSa_12mobile(self): """ author : 罗林 desc : SA新增,12位手机号 """ res = json.loads( WebAction.test_api_78dk_platform_sa_addSa( email=email, mobile=MockData.phone(12), name=name)) Assertion.verityContain(res['msg'], '手机格式不合法,') Assertion.verity(res['code'], '20000')
def test_014_ui_user_findUserBill_phone_overlong(self): """ Time :20120-04-10 author : 闫红 desc :逾期用户-列表,电话超长 """ phone = '131'+ MockData.phone(11) res = json.loads(Creditpay_urAction.test_ui_user_findUserBill(cardno='', loantimebegin='', loantimeend='', phone=phone, realname='', shouldrepaymentbegin='', shouldrepaymentend='', stage='', currentpage=1, pagesize=10)) Assertion.verity(res['code'], '10000') Assertion.verity(res['msg'], '成功')
import json import unittest from faker import Factory from common.myCommon import Assertion, TimeFormat from common.myCommon.TestBaseCase import TestBaseCase from common.myFile import MockData from ymjry.testAction import WebAction from ymjry.testAction import loginAction from ymjry.testAction import specialAction fake = Factory().create('zh_CN') bd_name = loginAction.sign + fake.name() email = loginAction.sign + fake.email() mobile = MockData.phone(11) bd_name1 = loginAction.sign + fake.name() email1 = loginAction.sign + fake.email() mobile1 = MockData.phone(11) class test_021_web_ombd(TestBaseCase): def test_001_api_78dk_platform_om_bd_addBdInfo_channeluuid_none(self): """ BD新增 渠道uuid 为空 :return: """ res = WebAction.test_api_78dk_platform_om_bd_addBdInfo(channeluuid='', email=email, mobile=mobile, name=bd_name)
@Author : 闫红 @File : test_002_web_ur.py @desc : 催收管理接口自动化 """ import json from common.myCommon import Assertion from common.myCommon.TestBaseCase import TestBaseCase from xyf.testAction import Creditpay_urAction, Creditpay_urAction_special from faker import Factory from common.myFile import MockData fake = Factory().create('zh_CN') carno = fake.ssn() phone = MockData.phone() name = fake.name() class test_002_web_ur(TestBaseCase): def test_001_ui_user_findUserBill(self): """ Time :20120-04-10 author : 闫红 desc :逾期用户-列表,筛选出所有逾期用户数据 """ res = json.loads(Creditpay_urAction.test_ui_user_findUserBill(cardno='', loantimebegin='', loantimeend='', phone='', realname='', shouldrepaymentbegin='', shouldrepaymentend='', stage='', currentpage=1, pagesize=10)) Assertion.verity(res['code'], '10000') Assertion.verity(res['msg'], '成功')