mirror of
https://github.com/fafhrd91/actix-web
synced 2025-06-25 22:49:21 +02:00
Add set_json
method to TestRequest (#851)
- Takes a type which implements serde::Serialize, serializes it to JSON, and sets it as the payload. The content-type is also set to JSON.
This commit is contained in:
@ -6,6 +6,8 @@
|
||||
|
||||
* Add `Query<T>::from_query()` to extract parameters from a query string. #846
|
||||
* `QueryConfig`, similar to `JsonConfig` for customizing error handling of query extractors.
|
||||
* Add `test::TestRequest::set_json` convenience method to automatically
|
||||
serialize data and set header in test requests.
|
||||
|
||||
### Changes
|
||||
|
||||
|
Reference in New Issue
Block a user