Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
InterfaceAutoTest
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
TestAuto
InterfaceAutoTest
Commits
34db1b95
Commit
34db1b95
authored
May 24, 2021
by
dengmaosheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交代码
parent
29e9c3d4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
1 deletions
+15
-1
test_case/bmc/test_accountinfo.py
+15
-1
test_case_data/bmc/bmc_login_20210513.xlsx
+0
-0
test_case_data/bmc/bmc_testcase_20210513.xlsx
+0
-0
No files found.
test_case/bmc/test_accountinfo.py
View file @
34db1b95
...
...
@@ -15,7 +15,7 @@ from config import BMCConfig
@allure.feature
(
"登录"
)
class
TestLogin
():
workBook
=
xlrd
.
open_workbook
(
f
'{BMCConfig.root_path}/test_case_data/bmc/bmc_login_20210513.xlsx'
)
@allure.story
(
"
账号信息基本功能
"
)
@allure.story
(
"
登录
"
)
@allure.severity
(
""
)
@allure.title
(
"{inData[testPoint]}"
)
@allure.testcase
(
"{inData[yapiAddress]}"
)
...
...
@@ -31,6 +31,20 @@ class TestLogin():
print
(
res
)
assert
res
[
'code'
]
==
expectData
[
'code'
]
@allure.story
(
"激活"
)
@allure.link
(
""
)
@allure.description
(
"/user/credit/idAuth"
)
@allure.title
(
"{inData[testPoint]}"
)
@pytest.mark.parametrize
(
"inData"
,
get_excelData
(
workBook
,
'登录'
,
'Active'
))
def
test_active
(
self
,
inData
):
url
=
f
"{BMCConfig().host}{inData['url']}"
method
=
inData
[
'method'
]
req_data
=
inData
[
'reqData'
]
expectData
=
inData
[
'expectData'
]
headers
=
config
.
BMCConfig
.
headers
res
=
request_main
(
url
=
url
,
headers
=
headers
,
method
=
method
,
data
=
req_data
)
print
(
res
)
assert
res
[
'code'
]
==
expectData
[
'code'
]
if
__name__
==
'__main__'
:
pytest
.
main
([
'-s'
,
'-v'
,
'test_accountinfo.py'
,
...
...
test_case_data/bmc/bmc_login_20210513.xlsx
View file @
34db1b95
No preview for this file type
test_case_data/bmc/bmc_testcase_20210513.xlsx
View file @
34db1b95
No preview for this file type
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment