*** Settings *** Documentation 客户端-更新职称名 Resource ../../../CommonConfig/Config.robot Resource ../../../AllApi/ClientAPI/PersonalInformationApi/CommonLoginAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/AddRanksAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/GetAllRanksAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/RemoveRanksAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/UpdateRankNameAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/GetRankByCodeAsync.robot *** Variables *** *** Test Cases *** Class_001_更新职称名 #随机生成职称名 ${raName} Random Characters ${raName1} Random Characters #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #添加职称信息 ${res1} AddRanksAsyncPost ${token} ${raName} ${organizationInfo_mao}[0] ${EMPTY} Log ${res1} #添加职称成功校验 ${flag1} Result Analysis ${res1} True ${EMPTY} ${EMPTY} Should Be True ${flag1} #获取新添加职称信息记录的RankCode ${rankCode} GetAllRanksAsyncPost_RankCode ${token} ${EMPTY} ${organizationInfo_mao}[0] #更新职称名 ${res2} UpdateRankNameAsyncPost ${token} ${rankCode} ${raName1} Log ${res2} #更新职称名校验 ${flag2} Result Analysis ${res2} True ${EMPTY} ${EMPTY} Should Be True ${flag2} ${res3} GetRankByCodeAsyncPost ${token} ${rankCode} ${content} Get From Dictionary ${res3} content ${rankName} Get From Dictionary ${content} RankName Should Be Equal As Strings ${rankName} ${raName1} #删除职称 ${response} RemoveRanksAsyncPost ${token} ${rankCode} #删除组织校验 ${flag2} Result Analysis ${response} True ${EMPTY} ${EMPTY} Should Be True ${flag2} Exception_001_更新职称名,Token非空校验 #更新职称名 ${res} UpdateRankNameAsyncPost ${EMPTY} ${EMPTY} ${EMPTY} Log ${res} #返回error信息校验 ${flag} Result Analysis ${res} false ${1} Permission validation error Should Be True ${flag} Exception_002_更新职称名,Token正确性校验 #更新职称名 ${res} UpdateRankNameAsyncPost 1111111 ${EMPTY} ${EMPTY} Log ${res} #返回error信息校验 ${flag} Result Analysis ${res} false ${1} Permission validation error Should Be True ${flag} Exception_003_更新职称名,RankCode非空校验校验 #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #更新职称名 ${res} UpdateRankNameAsyncPost ${token} ${EMPTY} 1111 Log ${res} #返回error信息校验 ${flag} Result Analysis ${res} false ${6022} RankCode can't be empty Should Be True ${flag} Exception_004_更新职称名,不存在的RankCode #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #更新职称名 ${res} UpdateRankNameAsyncPost ${token} 111 1111 Log ${res} #更新失败,result返回false ${flag} Result Analysis ${res} false ${EMPTY} ${EMPTY} Should Be True ${flag} Exception_005_更新职称名,RankName非空校验 #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #更新职称名 ${res} UpdateRankNameAsyncPost ${token} 1111 ${EMPTY} Log ${res} #返回error信息校验 ${flag} Result Analysis ${res} false ${6023} RankName can't be empty Should Be True ${flag} Exception_006_更新职称名,RankName重名校验 [Tags] inexecution Exception_007_更新职称名,RankName最大字符长度校验 [Tags] inexecution *** Keywords ***