Revert change

This commit is contained in:
FliegendeWurst 2017-01-10 22:19:08 +01:00
parent b602bbfe34
commit e59552e312
1 changed files with 4 additions and 4 deletions

View File

@ -18,8 +18,8 @@ macro_rules! run_test {
#[test]
fn test_root() {
// Check that the redirect works.
for method in vec![Get, Head].into_iter() {
let mut req = MockRequest::new(method, "/");
for method in &[Get, Head] {
let mut req = MockRequest::new(*method, "/");
run_test!(req, |mut response: Response| {
assert_eq!(response.status(), Status::SeeOther);
@ -32,8 +32,8 @@ fn test_root() {
}
// Check that other request methods are not accepted (and instead caught).
for method in vec![Post, Put, Delete, Options, Trace, Connect, Patch].into_iter() {
let mut req = MockRequest::new(method, "/");
for method in &[Post, Put, Delete, Options, Trace, Connect, Patch] {
let mut req = MockRequest::new(*method, "/");
run_test!(req, |mut response: Response| {
assert_eq!(response.status(), Status::NotFound);