mirror of https://github.com/fafhrd91/actix-web
clean up request test
This commit is contained in:
parent
398ef62e8f
commit
fae6fff499
|
@ -480,9 +480,12 @@ mod tests {
|
||||||
|
|
||||||
assert!(rmap.has_resource("/index.html"));
|
assert!(rmap.has_resource("/index.html"));
|
||||||
|
|
||||||
let req = TestRequest::default().rmap(rmap).to_http_request();
|
let req = TestRequest::default()
|
||||||
let route_name = req.0.rmap.match_name("/index.html");
|
.uri("/index.html")
|
||||||
assert_eq!(route_name.unwrap(), "index".to_owned());
|
.rmap(rmap)
|
||||||
|
.to_http_request();
|
||||||
|
|
||||||
|
assert_eq!(req.match_name(), Some("index"));
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
Loading…
Reference in New Issue