From e59552e312dfbc5e6f678ea8f1b112416c1eb1e3 Mon Sep 17 00:00:00 2001 From: FliegendeWurst <2012gdwu@web.de> Date: Tue, 10 Jan 2017 22:19:08 +0100 Subject: [PATCH] Revert change --- examples/handlebars_templates/src/tests.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/handlebars_templates/src/tests.rs b/examples/handlebars_templates/src/tests.rs index d2f7b765..89e2bfab 100644 --- a/examples/handlebars_templates/src/tests.rs +++ b/examples/handlebars_templates/src/tests.rs @@ -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);