*** Settings *** Documentation 客户端-搜索组织 Suite Setup Resource ../../../CommonConfig/Config.robot Resource ../../../AllApi/ClientAPI/PersonalInformationApi/CommonLoginAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/AddOrganizationsAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/SearchOrganizationsAsync.robot Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/RemoveOrganizationsAsync.robot *** Variables *** *** Test Cases *** Class_001_获取组织信息,组织类型为医院 [Template] #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #搜索组织,OrganizationType为0 ${res} SearchOrganizationsAsyncPost ${token} ${EMPTY} ${EMPTY} ${organizationType}[0] #校验返回不为空 ${content} Get From Dictionary ${res} content Should Not Be Empty ${content} Class_002_获取组织信息,组织类型为部门 [Template] #随机生成组织名 ${oranName} Random Characters #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #添加组织 ${res} AddOrganizationsAsyncPost ${token} ${oranName} ${organizationInfo_mao}[0] ${EMPTY} ${patientType}[0] ${languageCode}[0] Log ${res} #校验添加组织返回 ${flag} Result Analysis ${res} True ${EMPTY} ${EMPTY} Should Be True ${flag} #搜索组织,填写Keyword、OrganizationType为0 ${response} SearchOrganizationsAsyncPost ${token} ${oranName} ${organizationInfo_mao}[0] ${organizationType}[1] #校验搜索组织返回 ${content} Get From Dictionary ${response} content ${organizationName} Get From Dictionary ${content}[0] OrganizationName Should Be Equal As Strings ${organizationName} ${oranName} #搜索组织,返回OrganizationCode ${organizationCode} SearchOrganizationsAsyncOrganizationCode ${token} ${oranName} ${organizationInfo_mao}[0] ${organizationType}[1] #删除组织 ${res} RemoveOrganizationsAsyncPost ${token} ${organizationCode} Class_003_获取组织信息,填写OrganizationName中不包含的关键字 [Template] #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #搜索组织,关键字输入组织中不存在部门名称 ${res} SearchOrganizationsAsyncPost ${token} 88996677yayaya ${EMPTY} ${organizationType}[1] #校验返回为空 ${content} Get From Dictionary ${res} content Should Be Empty ${content} Class_004_获取组织信息,填写不存在下级部门的父级编码 [Template] #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #搜索组织,输入不存在的父级编码 ${res} SearchOrganizationsAsyncPost ${token} ${EMPTY} 88996677yayaya ${organizationType}[0] #校验返回为空 ${content} Get From Dictionary ${res} content Should Be Empty ${content} Class_005_获取组织信息,填写不存的组织类型 [Template] #登录,获取用户Token ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0} #搜索组织,输入不存在的组织类型 ${res} SearchOrganizationsAsyncPost ${token} ${EMPTY} ${EMPTY} 99 #校验返回为空 ${content} Get From Dictionary ${res} content Should Be Empty ${content} Exception_001_搜索组织,Token非空校验 [Template] #搜索组织,Token传入空值 ${res} SearchOrganizationsAsyncPost ${EMPTY} ${EMPTY} ${EMPTY} ${organizationType}[0] #返回error信息校验 ${flag} Result Analysis ${res} false ${1} Permission validation error Should Be True ${flag} Exception_002_搜索组织,Token正确性校验 [Template] #搜索组织,Token传入空值 ${res} SearchOrganizationsAsyncPost 11223344 ${EMPTY} ${EMPTY} ${organizationType}[0] #返回error信息校验 ${flag} Result Analysis ${res} false ${1} Permission validation error Should Be True ${flag} *** Keywords ***