Commit 455bb066 by sanshi

文件上传

parent 27790a33
......@@ -115,6 +115,7 @@ class TestFileUpload(object):
case_path = WorkBase().case_path
_file = open(case_path + "APP\\File\\case.txt", "rb")
response = self.file_upload(token=self.token, _file=_file)
assert ".txt" in response
if __name__ == "__main__":
......@@ -124,11 +125,11 @@ if __name__ == "__main__":
import os
# 执行自动化测试用例
# case_info = os.path.split(__file__)
# case = UtilsCmd().pytest_cmd()
# r = UtilsPyTest(case=case, case_info=case_info)
# r.run_main()
a = TestFileUpload()
a.setup_class()
a.test_case_04()
case_info = os.path.split(__file__)
case = UtilsCmd().pytest_cmd()
r = UtilsPyTest(case=case, case_info=case_info)
r.run_main()
# a = TestFileUpload()
# a.setup_class()
# a.test_case_04()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment