mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-04 23:16:57 +08:00
add test result flag
This commit is contained in:
+7
-3
@@ -1,12 +1,12 @@
|
|||||||
import os
|
|
||||||
import argparse
|
import argparse
|
||||||
import logging
|
import logging
|
||||||
|
import os
|
||||||
|
|
||||||
import PyUnitReport
|
import PyUnitReport
|
||||||
|
|
||||||
from ate import __version__
|
from ate import __version__
|
||||||
from ate.task import create_task
|
from ate.task import create_task
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
""" parse command line options and run commands.
|
""" parse command line options and run commands.
|
||||||
"""
|
"""
|
||||||
@@ -44,6 +44,7 @@ def main():
|
|||||||
report name is ignored, use generated time instead.")
|
report name is ignored, use generated time instead.")
|
||||||
|
|
||||||
results = {}
|
results = {}
|
||||||
|
flag = "SUCCESS"
|
||||||
|
|
||||||
for testset_path in set(args.testset_paths):
|
for testset_path in set(args.testset_paths):
|
||||||
|
|
||||||
@@ -65,4 +66,7 @@ def main():
|
|||||||
"skipped": len(result.skipped)
|
"skipped": len(result.skipped)
|
||||||
}
|
}
|
||||||
|
|
||||||
return results
|
if len(result.successes) != result.testsRun:
|
||||||
|
flag = "FAILED"
|
||||||
|
|
||||||
|
return flag, results
|
||||||
|
|||||||
Reference in New Issue
Block a user