123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384 |
- *** Settings ***
- Documentation 分页查询上级机构列表
- Resource ../../../CommonConfig/Config.robot
- Resource ../../../AllApi/ClientAPI/PersonalInformationApi/CommonLoginAsync.robot
- Resource ../../../AllApi/ClientAPI/OrganizationInformationApi/FindPatientOrganizationsByPageAsync.robot
- *** Test Cases ***
- Class_001_分页查询上级机构列表
- #登录,获取用户Token
- ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0}
- #查询上级机构列表
- ${res} FindPatientOrganizationsByPageAsyncPost ${token} 1 1000000 ${EMPTY}
- log ${res}
- ${content} Get From Dictionary ${res} content
- @{list} Get From Dictionary ${content} PageData
- ${organizationCodes} Create List
- FOR ${value} IN @{list}
- ${organizationCode} Get From Dictionary ${value} OrganizationCode
- Append To List ${organizationCodes} ${organizationCode}
- END
- #校验,返回的数据中不包含用户自己所在的医院
- log @{organizationInfo_mao}
- List Should Not Contain Value ${organizationCodes} @{organizationInfo_mao}
- Class_002_分页查询上级机构列表,设置页大小
- #登录,获取用户Token
- ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0}
- ${pageSize} Set Variable 20
- #查询上级机构列表
- ${res} FindPatientOrganizationsByPageAsyncPost ${token} 1 ${pageSize} ${EMPTY}
- log ${res}
- #校验
- ${content} Get From Dictionary ${res} content
- ${pageSize1} Get From Dictionary ${content} PageSize
- Should Be Equal As Strings ${pageSize1} ${pageSize}
- Class_003_分页查询上级机构列表,设置当前页
- #登录,获取用户Token
- ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0}
- ${pageIndex} Set Variable 20
- #查询上级机构列表
- ${res} FindPatientOrganizationsByPageAsyncPost ${token} ${pageIndex} 10 ${EMPTY}
- log ${res}
- #校验
- ${content} Get From Dictionary ${res} content
- ${pageIndex1} Get From Dictionary ${content} PageIndex
- Should Be Equal As Strings ${pageIndex1} ${pageIndex}
- Class_004_分页查询上级机构列表,传入存在的KeyWord
- #登录,获取用户Token
- ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0}
- #查询上级机构列表
- ${res} FindPatientOrganizationsByPageAsyncPost ${token} 1 10 jo
- log ${res}
- #校验
- ${content} Get From Dictionary ${res} content
- ${totalCount} Get From Dictionary ${content} TotalCount
- Should Not Be Equal As Integers ${totalCount} 0
- Class_005_分页查询上级机构列表,传入不存在的KeyWord
- #登录,获取用户Token
- ${token} GetCommonLoginAsyncToken ${user_mao}[0] ${EMPTY} ${user_mao}[1] ${3} ${0}
- #查询上级机构列表
- ${res} FindPatientOrganizationsByPageAsyncPost ${token} 1 10 @!#$%^rfghj
- log ${res}
- ${content} Get From Dictionary ${res} content
- ${totalCount} Get From Dictionary ${content} TotalCount
- Should Be Equal As Integers ${totalCount} 0
- Exception_001_分页查询上级机构列表,Token非空校验
- #查询上级机构列表
- ${res} FindPatientOrganizationsByPageAsyncPost ${EMPTY} 1 10 ${EMPTY}
- log ${res}
- #返回error信息校验
- ${flag} Result Analysis ${res} false ${1} Permission validation error
- Should Be True ${flag}
- Exception_002_分页查询上级机构列表,Token正确性校验
- #查询上级机构列表
- ${res} FindPatientOrganizationsByPageAsyncPost 1111 1 10 ${EMPTY}
- log ${res}
- #返回error信息校验
- ${flag} Result Analysis ${res} false ${1} Permission validation error
- Should Be True ${flag}
|