mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-13 17:29:56 +08:00
fix: convert har to JSON format testcase
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
**Fixed**
|
||||
|
||||
- fix: avoid '.csv' been converted to '_csv'
|
||||
- fix: convert har to JSON format testcase
|
||||
|
||||
## 3.0.12 (2020-06-14)
|
||||
|
||||
|
||||
@@ -67,7 +67,7 @@ def main_har2case(args):
|
||||
|
||||
if args.to_yaml:
|
||||
output_file_type = "YAML"
|
||||
elif args.to_yaml:
|
||||
elif args.to_json:
|
||||
output_file_type = "JSON"
|
||||
else:
|
||||
output_file_type = "pytest"
|
||||
|
||||
@@ -338,8 +338,6 @@ class HarParser(object):
|
||||
capture_exception(ex)
|
||||
raise
|
||||
|
||||
logger.debug("prepared testcase: {}".format(testcase))
|
||||
|
||||
if file_type == "JSON":
|
||||
output_testcase_file = f"{harfile}.json"
|
||||
utils.dump_json(testcase, output_testcase_file)
|
||||
|
||||
Reference in New Issue
Block a user