Adjust spacing in handlebars_templates example.

This commit is contained in:
Sergio Benitez 2017-01-13 00:22:16 -08:00
parent 99a17b42ae
commit 725191d3c3
1 changed files with 6 additions and 8 deletions

View File

@ -22,11 +22,9 @@ fn test_root() {
let mut req = MockRequest::new(*method, "/");
run_test!(req, |mut response: Response| {
assert_eq!(response.status(), Status::SeeOther);
assert!(response.body().is_none());
let location_headers: Vec<_> = response.header_values("Location").collect();
assert_eq!(location_headers, vec!["/hello/Unknown"]);
});
}
@ -58,8 +56,8 @@ fn test_name() {
name: "Jack".to_string(),
items: vec!["One", "Two", "Three"].iter().map(|s| s.to_string()).collect()
};
let expected = Template::render("index", &context).to_string();
let expected = Template::render("index", &context).to_string();
let body_string = response.body().and_then(|body| body.into_string());
assert_eq!(body_string, Some(expected));
});