1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-07-01 16:55:08 +02:00

Check format and tweak CI config (#1619)

This commit is contained in:
Yuki Okushi
2020-07-22 08:28:33 +09:00
committed by GitHub
parent 701bdacfa2
commit 92b5bcd13f
45 changed files with 276 additions and 272 deletions

View File

@ -626,7 +626,7 @@ mod tests {
Ok(())
};
let s = format!("{}", FormatDisplay(&render));
assert!(s.contains(&format!("{}", now.format("%Y-%m-%dT%H:%M:%S"))));
assert!(s.contains(&now.format("%Y-%m-%dT%H:%M:%S")));
}
#[actix_rt::test]

View File

@ -91,9 +91,9 @@ where
// That approach fails when a trailing slash is added,
// and a duplicate slash is removed,
// since the length of the strings remains the same
//
//
// For example, the path "/v1//s" will be normalized to "/v1/s/"
// Both of the paths have the same length,
// Both of the paths have the same length,
// so the change can not be deduced from the length comparison
if path != original_path {
let mut parts = head.uri.clone().into_parts();
@ -129,7 +129,7 @@ mod tests {
let mut app = init_service(
App::new()
.wrap(NormalizePath::default())
.service(web::resource("/v1/something/").to(|| HttpResponse::Ok())),
.service(web::resource("/v1/something/").to(HttpResponse::Ok)),
)
.await;