mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-05 07:26:55 +08:00
print warning message when no testcase found
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
__title__ = 'HttpRunner'
|
__title__ = 'HttpRunner'
|
||||||
__description__ = 'One-stop solution for HTTP(S) testing.'
|
__description__ = 'One-stop solution for HTTP(S) testing.'
|
||||||
__url__ = 'https://github.com/HttpRunner/HttpRunner'
|
__url__ = 'https://github.com/HttpRunner/HttpRunner'
|
||||||
__version__ = '1.2.0-beta'
|
__version__ = '1.2.1-beta'
|
||||||
__author__ = 'debugtalk'
|
__author__ = 'debugtalk'
|
||||||
__author_email__ = 'mail@debugtalk.com'
|
__author_email__ = 'mail@debugtalk.com'
|
||||||
__license__ = 'MIT'
|
__license__ = 'MIT'
|
||||||
|
|||||||
@@ -215,6 +215,7 @@ class HttpRunner(object):
|
|||||||
mapping = mapping or {}
|
mapping = mapping or {}
|
||||||
task_suite = TaskSuite(self.path, mapping)
|
task_suite = TaskSuite(self.path, mapping)
|
||||||
except exception.TestcaseNotFound:
|
except exception.TestcaseNotFound:
|
||||||
|
logger.log_error("Testcases not found in {}".format(self.path))
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
|
|
||||||
result = self.runner.run(task_suite)
|
result = self.runner.run(task_suite)
|
||||||
|
|||||||
@@ -485,6 +485,9 @@ def load_test_file(file_path):
|
|||||||
api_info.update(item["api"])
|
api_info.update(item["api"])
|
||||||
testset["api"][func_name] = api_info
|
testset["api"][func_name] = api_info
|
||||||
|
|
||||||
|
else:
|
||||||
|
logger.log_warning("unexpected block: {}. block should only be config or test.".format(key))
|
||||||
|
|
||||||
return testset
|
return testset
|
||||||
|
|
||||||
def get_testinfo_by_reference(ref_name, ref_type):
|
def get_testinfo_by_reference(ref_name, ref_type):
|
||||||
|
|||||||
Reference in New Issue
Block a user