mirror of
https://github.com/httprunner/httprunner.git
synced 2026-06-03 06:49:38 +08:00
Merge pull request #850 from httprunner/leo_dev
2.5.4 **Fixed** - fix: HTTP method missed "CONNECT", "TRACE" **Changed** - change: remove method validation from runner.Runner
This commit is contained in:
@@ -1,5 +1,15 @@
|
|||||||
# Release History
|
# Release History
|
||||||
|
|
||||||
|
## 2.5.5 (2020-01-06)
|
||||||
|
|
||||||
|
**Fixed**
|
||||||
|
|
||||||
|
- fix: HTTP method missed "CONNECT", "TRACE"
|
||||||
|
|
||||||
|
**Changed**
|
||||||
|
|
||||||
|
- change: remove method validation from runner.Runner
|
||||||
|
|
||||||
## 2.5.4 (2020-01-03)
|
## 2.5.4 (2020-01-03)
|
||||||
|
|
||||||
**Added**
|
**Added**
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
__version__ = "2.5.4"
|
__version__ = "2.5.5"
|
||||||
__description__ = "One-stop solution for HTTP(S) testing."
|
__description__ = "One-stop solution for HTTP(S) testing."
|
||||||
|
|
||||||
__all__ = ["__version__", "__description__"]
|
__all__ = ["__version__", "__description__"]
|
||||||
|
|||||||
@@ -136,7 +136,9 @@
|
|||||||
"HEAD",
|
"HEAD",
|
||||||
"PUT",
|
"PUT",
|
||||||
"PATCH",
|
"PATCH",
|
||||||
"DELETE"
|
"DELETE",
|
||||||
|
"CONNECT",
|
||||||
|
"TRACE"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"url": {
|
"url": {
|
||||||
|
|||||||
@@ -230,14 +230,6 @@ class Runner(object):
|
|||||||
except KeyError:
|
except KeyError:
|
||||||
raise exceptions.ParamsError("URL or METHOD missed!")
|
raise exceptions.ParamsError("URL or METHOD missed!")
|
||||||
|
|
||||||
# TODO: move method validation to json schema
|
|
||||||
valid_methods = ["GET", "HEAD", "POST", "PUT", "PATCH", "DELETE", "OPTIONS"]
|
|
||||||
if method.upper() not in valid_methods:
|
|
||||||
err_msg = u"Invalid HTTP method! => {}\n".format(method)
|
|
||||||
err_msg += "Available HTTP methods: {}".format("/".join(valid_methods))
|
|
||||||
logger.log_error(err_msg)
|
|
||||||
raise exceptions.ParamsError(err_msg)
|
|
||||||
|
|
||||||
logger.log_info("{method} {url}".format(method=method, url=parsed_url))
|
logger.log_info("{method} {url}".format(method=method, url=parsed_url))
|
||||||
logger.log_debug(
|
logger.log_debug(
|
||||||
"request kwargs(raw): {kwargs}".format(kwargs=parsed_test_request))
|
"request kwargs(raw): {kwargs}".format(kwargs=parsed_test_request))
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "httprunner"
|
name = "httprunner"
|
||||||
version = "2.5.4"
|
version = "2.5.5"
|
||||||
description = "One-stop solution for HTTP(S) testing."
|
description = "One-stop solution for HTTP(S) testing."
|
||||||
license = "Apache-2.0"
|
license = "Apache-2.0"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
|
|||||||
Reference in New Issue
Block a user